Made enemies die
This commit is contained in:
14
Assets/Scripts/EnemyController.cs
Normal file
14
Assets/Scripts/EnemyController.cs
Normal file
@@ -0,0 +1,14 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace InterfaceOff.WorldScene
|
||||
{
|
||||
public class EnemyController : MonoBehaviour
|
||||
{
|
||||
[SerializeField] private PlayerController Player;
|
||||
[SerializeField] private int DeathIndex = 500;
|
||||
[SerializeField] private GameObject Renderer;
|
||||
|
||||
private void Update() =>
|
||||
Renderer.SetActive(DeathIndex > Player.FrameIndex);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user