Exemple #1
0
 private void SetTarget()
 {
     if (reachableTiles.Displaying)
     {
         TileProperties targetTile = GetTile();
         if (targetTile.movingEntity || targetTile.ActionPointCost > motherShip.Inventory.GetResource(motherShip.fuelResource) || targetTile == motherShip.Movable.CurrentTile ||
             !targetTile.IsWalkable())
         {
             targetTile = null;
             reachableTiles.UndisplayReachables();
         }
         else
         {
             motherShip.targetTile = targetTile;
             reachableTiles.ValidReachables();
             motherShip.ClearActiveActionPoints();
         }
     }
 }