Ejemplo n.º 1
0
 public virtual void Die()
 {
     if (Dead)
     {
         return; //can't die twice
     }
     movement.CurrentDirection = new Vector2(0, 0);
     selection.Deselect();
     soundPlayer.PlayDyingSound();
     dyingAnimation.Start();
     TurnOffComponents();
     TurnOffChildGameObjects();
     Dead = true;
     Debug.Log("DEAD!");
 }
Ejemplo n.º 2
0
 public void RemoveFromSelection(UnitSelection unitSelection)
 {
     unitSelection.Deselect();
     SelectedUnits.Remove(unitSelection);
 }