This commit is contained in:
Vova
2023-06-22 10:42:56 +03:00
parent 49da969226
commit 1199eba852
8 changed files with 230 additions and 0 deletions
+15
View File
@@ -0,0 +1,15 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class DoorController : MonoBehaviour
{
private void OnTriggerEnter2D(Collider2D collision)
{
if (collision.tag == "Player")
{
//if player have key, door will open
//else player can't pass
}
}
}