21 lines
523 B
C#
21 lines
523 B
C#
using Sirenix.OdinInspector;
|
|
using UnityEngine;
|
|
|
|
namespace Reset.Units{
|
|
public class EnemyCombat : UnitCombat, IUnitTargetProvider{
|
|
public GameObject target;
|
|
public GameObject UnitTarget => target;
|
|
|
|
[Button]
|
|
public void SetNewTarget(GameObject newTarget){
|
|
Unit.Graph.SendEvent("New Target Detected");
|
|
target = newTarget;
|
|
}
|
|
|
|
public void DropTarget(){
|
|
target = null;
|
|
Unit.Graph.SendEvent("Drop Target");
|
|
}
|
|
}
|
|
}
|