From 2d7da5132c0f086fb871ceff8811758bede542bf Mon Sep 17 00:00:00 2001 From: Kjell Iwarson Date: Wed, 26 Apr 2017 18:33:10 +0200 Subject: [PATCH] Spawn powerui --- Assets/scripts/LoadAssets.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Assets/scripts/LoadAssets.cs b/Assets/scripts/LoadAssets.cs index 187c61a..ca78d1a 100644 --- a/Assets/scripts/LoadAssets.cs +++ b/Assets/scripts/LoadAssets.cs @@ -341,7 +341,11 @@ public IEnumerator BeginPlaying() spawner.AddComponent().ballPrefab = NetworkManager.singleton.spawnPrefabs[0];// Don't like this at all... spawner.AddComponent(); - if (GameObject.FindGameObjectsWithTag("Score").Length <= 0) + //Create the power UI for the players + const string powerUIPrefab = "entities/powers/PowerUI"; + Instantiate(Resources.Load(powerUIPrefab)); + + if (GameObject.FindGameObjectsWithTag("Score").Length <= 0) { GameObject scoreManager = GameObject.Instantiate(NetworkManager.singleton.spawnPrefabs[1]);