tower col

This commit is contained in:
Sveske Juice 2024-04-21 04:14:39 +02:00
parent a29568067f
commit 676a6935f7
2 changed files with 15 additions and 0 deletions

View File

@ -21,6 +21,13 @@ MonoBehaviour:
price: 250 price: 250
prefab: {fileID: 1415246146501367120, guid: 91554800af50ec827822f376e2fc5f64, prefab: {fileID: 1415246146501367120, guid: 91554800af50ec827822f376e2fc5f64,
type: 3} type: 3}
- name: Mr Lazer
price: 500
prefab: {fileID: 645933633211530419, guid: 4e5e3131ea2a78cfd93219be3806da6d, type: 3}
- name: Tesla
price: 500
prefab: {fileID: 1328109535653931045, guid: 148ea27cfb89dc0398835d59bed11cca,
type: 3}
- name: Black hole - name: Black hole
price: 500 price: 500
prefab: {fileID: 4611178744751000815, guid: 1d7949721a9f0bc9ba1a8c49ca5fd099, prefab: {fileID: 4611178744751000815, guid: 1d7949721a9f0bc9ba1a8c49ca5fd099,

View File

@ -17,6 +17,14 @@ public class CameraSlotClickDetect : MonoBehaviour
{ {
ShootClickRay(); ShootClickRay();
} }
if (Input.GetKeyDown(KeyCode.Escape))
{
GameManager.Instance.SelectedTower = null;
if (towerCam != null)
towerCam.ChangeToTarget(null);
else
Debug.LogWarning("TowerCam scpritet is not assigned, assign in the inspector");
}
ShootHoverRay(); ShootHoverRay();
} }