Beispiel #1
0
 private void RaiseOnBoardLoaded(BoardDef board)
 {
     if (OnBoardLoaded != null)
     {
         OnBoardLoaded(board);
     }
 }
Beispiel #2
0
 public void ShowLevel(BoardDef boardDef)
 {
     ClearMovableTiles();
     for (int x = 0; x < boardDef.w; ++x)
     {
         for (int y = 0; y < boardDef.h; ++y)
         {
             CreateMovableTile(x, y, boardDef.GetTile(x, y));
         }
     }
 }
Beispiel #3
0
 void OnLevelLoaded(LevelDef level)
 {
     _boardDef = level.board;
     // Raise an event for the board inside this level. This is a useful indirection because the undo system will use boards.
     RaiseOnBoardLoaded(level.board);
 }
Beispiel #4
0
 private void OnBoardLoaded(BoardDef boardDef)
 {
     ShowLevel(boardDef);
 }