Пример #1
0
 private void setMoveState(List <Tile> tiles, TileDisplayState moveState)
 {
     foreach (Tile tile in tiles)
     {
         tile.setState(moveState);
     }
 }
Пример #2
0
 public void setState(TileDisplayState state)
 {
     this.state = state;
     Destroy(displayedOverlay);
     if (state == TileDisplayState.ATTACK)
     {
         displayedOverlay = Instantiate(attackOverlay, this.gameObject.transform) as GameObject;
     }
     if (state == TileDisplayState.MOVE)
     {
         displayedOverlay = Instantiate(moveOverlay, this.gameObject.transform) as GameObject;
     }
     if (state == TileDisplayState.NONE)
     {
         //No Op
     }
 }