protected override void Start() { base.Start(); // Start Looking To Player spriteDirection.FaceDirection(LookAtPlayer.LookToPlayerDirection(transform.position)); // notify GameEvents.Enemies.ZombieSpawned.SafeCall(); }
protected override void Start() { // Start Looking To Player spriteDirection.FaceDirection(LookAtPlayer.LookToPlayerDirection(transform.position)); // wait for cooldown before starts shooting canShoot = false; MyExtensions.WaitAndAct(this, shootingCooldown, () => canShoot = true); //notify spawn GameEvents.Enemies.WoodyPigSpawned.SafeCall(); }
public void LookToPlayer() { spriteDirection.FaceDirection(LookAtPlayer.LookToPlayerDirection(transform.position)); }
public void TurnToPlayer() { FaceDirection(LookAtPlayer.LookToPlayerDirection(transform.position)); }