Beispiel #1
0
 public override bool moveTo(Square s)
 {
     if (s != null)
     {
         if (s.isWalkable())
         {
             if (s.mayContainBarricade())
             {
                 if (s.isOccupied())
                 {
                     return false;
                 }
                 else
                 {
                     s.Piece = this;
                     Square = s;
                     Player.Baricade = null;
                     Player = null;
                     return true;
                 }
             }
         }
     }
     return false;
 }