Пример #1
0
 public void MoveCommandUnit(Cell newCell)
 {
     if (ActiveEffect == ActiveEffectTypes.UnitMove ||
         ActiveEffect == ActiveEffectTypes.UnitDisengage ||
         ActiveEffect == ActiveEffectTypes.UnitForceMove ||
         ActiveEffect == ActiveEffectTypes.UnitUseSpeed ||
         ActiveEffect == ActiveEffectTypes.UnitUseDisengageSpeed)
     {
         if (newCell.occupantCounter == null)
         {
             if (SelectedUnit.CheckOccupancy(newCell) || ActiveEffect == ActiveEffectTypes.UnitForceMove)
             {
                 RemoveUnitCounter(SelectedUnit.UnitCounter);
                 CreateUnitCounter(SelectedUnit, newCell, false);
                 SelectedUnit.UnitCounter.ShowUnitSelector(true);
                 RefreshEffectManager();
                 GameManager.instance.uiManager.RefreshUI();
             }
         }
     }
 }