예제 #1
0
    private void OnTriggerEnter(Collider other)
    {
        ITakeDamage droid = other.GetComponent <ITakeDamage>();

        if (droid is EnemyHealth)
        {
            droid?.OnHit(damage);
        }
    }