상속: UnityEngine.MonoBehaviour
예제 #1
0
파일: Actor.cs 프로젝트: lmucs/Coliseo
 // I don't think this will ever be used, at least not while the colliders are set up as they are.
 public void attack(Actor target)
 {
     target.TakeDamage(attackStrength);
 }
예제 #2
0
파일: Actor.cs 프로젝트: lmucs/Coliseo
 bool IsOpponent(Actor other)
 {
     return this.GetType() != other.GetType();
 }
예제 #3
0
파일: Actor.cs 프로젝트: lmucs/Coliseo
 bool IsValidAttack(Actor other)
 {
     return other && IsOpponent(other) && other.attacking;
 }
예제 #4
0
파일: Spawn.cs 프로젝트: lmucs/Coliseo
 void Start()
 {
     enemy = Instantiate<GameObject>(enemy);
     enemy.transform.position = transform.position;
     actor = enemy.GetComponent<Actor>();
 }