Пример #1
0
 public void ClearPath()
 {
     if (currentPathExists)
     {
         HexCell current = currentPathTo;
         while (current != currentPathFrom)
         {
             current.SetLabel(null);
             current.DisableHightlight();
             current = current.PathFrom;
         }
         current.DisableHightlight();
         currentPathExists = false;
     }
     else if (currentPathFrom)
     {
         currentPathFrom.DisableHightlight();
         currentPathTo.DisableHightlight();
     }
     currentPathFrom = currentPathTo = null;
 }