diff --git a/Assets/Scripts/PlacementSystem/PlacementManager.cs b/Assets/Scripts/PlacementSystem/PlacementManager.cs index f24d0fb..c6599cb 100644 --- a/Assets/Scripts/PlacementSystem/PlacementManager.cs +++ b/Assets/Scripts/PlacementSystem/PlacementManager.cs @@ -105,7 +105,7 @@ public class TowerPlacementManager : MonoBehaviour OnDeselectSlot(CurrentSelectedSlot, slot); CurrentSelectedSlot = slot; - slot.gameObject.GetComponentInChildren().material.color = Color.blue; + slot.gameObject.GetComponentInChildren().material.color = default; } // Called when another slot is getting selected @@ -142,10 +142,13 @@ public class TowerPlacementManager : MonoBehaviour //SilhouettedObject.SetActive(true); SilhouettedObject.transform.parent = slot.TowerSpawnPoint.transform; SilhouettedObject.transform.localPosition = offset; + + slot.gameObject.GetComponentInChildren().material.color = Color.white; } public void OnSlotUnHovered(SlotManager slot, GridManager grid, int x, int y) { + slot.gameObject.GetComponentInChildren().material.color = default; Destroy(SilhouettedObject); } @@ -153,7 +156,6 @@ public class TowerPlacementManager : MonoBehaviour { Destroy(SilhouettedObject); OnTowerPlaced?.Invoke(SelectedTowerInfo); - }