Revert "Project modernization (#630)"

This code was not tested and breaks in Release builds, reverting to restore
functionality of the nightly. All in-game menus do not work and generating
a world crashes.

This reverts commit a9be52c41a.
This commit is contained in:
Loki Rautio
2026-03-07 21:12:22 -06:00
parent a9be52c41a
commit 087b7e7abf
1373 changed files with 19449 additions and 19903 deletions

View File

@@ -13,34 +13,34 @@
//public static final Biome[] biomes = new Biome[256];
Biome *Biome::biomes[256];
Biome *Biome::ocean = nullptr;
Biome *Biome::plains = nullptr;
Biome *Biome::desert = nullptr;
Biome *Biome::ocean = NULL;
Biome *Biome::plains = NULL;
Biome *Biome::desert = NULL;
Biome *Biome::extremeHills = nullptr;
Biome *Biome::forest = nullptr;
Biome *Biome::taiga = nullptr;
Biome *Biome::extremeHills = NULL;
Biome *Biome::forest = NULL;
Biome *Biome::taiga = NULL;
Biome *Biome::swampland = nullptr;
Biome *Biome::river = nullptr;
Biome *Biome::swampland = NULL;
Biome *Biome::river = NULL;
Biome *Biome::hell = nullptr;
Biome *Biome::sky = nullptr;
Biome *Biome::hell = NULL;
Biome *Biome::sky = NULL;
Biome *Biome::frozenOcean = nullptr;
Biome *Biome::frozenRiver = nullptr;
Biome *Biome::iceFlats = nullptr;
Biome *Biome::iceMountains = nullptr;
Biome *Biome::mushroomIsland = nullptr;
Biome *Biome::mushroomIslandShore = nullptr;
Biome *Biome::beaches = nullptr;
Biome *Biome::desertHills = nullptr;
Biome *Biome::forestHills = nullptr;
Biome *Biome::taigaHills = nullptr;
Biome *Biome::smallerExtremeHills = nullptr;
Biome *Biome::frozenOcean = NULL;
Biome *Biome::frozenRiver = NULL;
Biome *Biome::iceFlats = NULL;
Biome *Biome::iceMountains = NULL;
Biome *Biome::mushroomIsland = NULL;
Biome *Biome::mushroomIslandShore = NULL;
Biome *Biome::beaches = NULL;
Biome *Biome::desertHills = NULL;
Biome *Biome::forestHills = NULL;
Biome *Biome::taigaHills = NULL;
Biome *Biome::smallerExtremeHills = NULL;
Biome *Biome::jungle = nullptr;
Biome *Biome::jungleHills = nullptr;
Biome *Biome::jungle = NULL;
Biome *Biome::jungleHills = NULL;
void Biome::staticCtor()
@@ -86,8 +86,8 @@ Biome::Biome(int id) : id(id)
color = 0;
// snowCovered = false; // 4J - this isn't set by the java game any more so removing to save confusion
topMaterial = static_cast<byte>(Tile::grass_Id);
material = static_cast<byte>(Tile::dirt_Id);
topMaterial = (byte) Tile::grass_Id;
material = (byte) Tile::dirt_Id;
leafColor = 0x4EE031;
_hasRain = true;
depth = 0.1f;
@@ -95,7 +95,7 @@ Biome::Biome(int id) : id(id)
temperature = 0.5f;
downfall = 0.5f;
//waterColor = 0xffffff; // 4J Stu - Not used
decorator = nullptr;
decorator = NULL;
m_grassColor = eMinecraftColour_NOT_SET;
m_foliageColor = eMinecraftColour_NOT_SET;
@@ -132,7 +132,7 @@ Biome::Biome(int id) : id(id)
Biome::~Biome()
{
if(decorator != nullptr) delete decorator;
if(decorator != NULL) delete decorator;
}
BiomeDecorator *Biome::createDecorator()
@@ -228,7 +228,7 @@ vector<Biome::MobSpawnerData *> *Biome::getMobs(MobCategory *category)
if (category == MobCategory::creature_wolf) return &friendlies_wolf;
if (category == MobCategory::creature_mushroomcow) return &friendlies_mushroomcow;
if (category == MobCategory::ambient) return &ambientFriendlies;
return nullptr;
return NULL;
}
bool Biome::hasSnow()
@@ -261,12 +261,12 @@ float Biome::getCreatureProbability()
int Biome::getDownfallInt()
{
return static_cast<int>(downfall * 65536);
return (int) (downfall * 65536);
}
int Biome::getTemperatureInt()
{
return static_cast<int>(temperature * 65536);
return (int) (temperature * 65536);
}
// 4J - brought forward from 1.2.3