Beispiel #1
0
 public void GenerateWorld(bool GenerateWhileInPlayMode, bool LoadCostField)
 {
     if (GenerateWhileInPlayMode)
     {
         GetComponent <SaveLoad>().LoadLevel();
         worldData.GenerateWorld(this, GenerateWhileInPlayMode, LoadCostField);
         worldData.Setup();
     }
     else
     {
         if (LoadCostField)
         {
             GetComponent <SaveLoad>().LoadLevel();
             worldData.GenerateWorld(this, GenerateWhileInPlayMode, LoadCostField);
         }
         else
         {
             worldData.costFields.Clear();
             worldData.GenerateWorld(this, GenerateWhileInPlayMode, LoadCostField);
         }
     }
 }
Beispiel #2
0
 private void GenerateWorldManually(List <Tile[][]> tileGrids, List <IntVector2> tileGridOffset,
                                    bool autoConnectWorldAreas)
 {
     worldData.GenerateWorldManually(this, tileGrids, tileGridOffset, autoConnectWorldAreas);
     worldData.Setup();
 }