19 lines
425 B
C#
19 lines
425 B
C#
using DragonLi.Frame;
|
|
using UnityEngine;
|
|
|
|
public class SDRRMIHand : MonoBehaviour
|
|
{
|
|
public float atk = 0f;
|
|
public void OnTriggerEnter(Collider other)
|
|
{
|
|
if (other.tag == "Tower")
|
|
{
|
|
IDamagable component = other.gameObject.GetComponent<IDamagable>();
|
|
if (component != null)
|
|
{
|
|
component.ApplyDamage(atk, null, null);
|
|
}
|
|
}
|
|
}
|
|
}
|