Преглед изворни кода

Paint native terrain in zones.

DjWarmonger пре 11 година
родитељ
комит
3a6f748fb5
1 измењених фајлова са 3 додато и 0 уклоњено
  1. 3 0
      lib/rmg/CRmgTemplateZone.cpp

+ 3 - 0
lib/rmg/CRmgTemplateZone.cpp

@@ -368,6 +368,9 @@ bool CRmgTemplateZone::fill(CMapGenerator* gen)
 			playerInfo.posOfMainTown = town->pos - int3(2, 0, 0);
 			playerInfo.generateHeroAtMainTown = true;
 
+			gen->editManager->getTerrainSelection().selectRange(MapRect(shape[0], shape[2].y - shape[0].y, shape[2].x - shape[0].x));
+			gen->editManager->drawTerrain(VLC->townh->factions[townId]->nativeTerrain, &gen->rand);
+
 			//required_objects.push_back(town);
 
 			std::vector<Res::ERes> required_mines;