1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Finish and clean up mapgen configuration

This commit is contained in:
kwolekr 2013-01-06 14:40:24 -05:00 committed by Perttu Ahola
parent 45cf32afc5
commit 631a835e07
13 changed files with 395 additions and 341 deletions

View file

@ -78,7 +78,7 @@ BiomeDefManager::BiomeDefManager(IGameDef *gamedef) {
BiomeDefManager::~BiomeDefManager() {
for (int i = 0; i != bgroups.size(); i++)
for (unsigned int i = 0; i != bgroups.size(); i++)
delete bgroups[i];
}
@ -96,6 +96,7 @@ Biome *BiomeDefManager::createBiome(BiomeTerrainType btt) {
case BIOME_TERRAIN_FLAT:
return new BiomeSuperflat;
}
return NULL;
}
@ -116,7 +117,7 @@ void BiomeDefManager::addBiomeGroup(float freq) {
void BiomeDefManager::addBiome(Biome *b) {
std::vector<Biome *> *bgroup;
if (b->groupid >= bgroups.size()) {
if ((unsigned int)b->groupid >= bgroups.size()) {
errorstream << "BiomeDefManager: attempted to add biome '" << b->name
<< "' to nonexistent biome group " << b->groupid << std::endl;
return;
@ -131,7 +132,6 @@ void BiomeDefManager::addBiome(Biome *b) {
void BiomeDefManager::addDefaultBiomes() {
std::vector<Biome *> *bgroup;
Biome *b;
b = new Biome;