mirror of
https://github.com/smartcmd/MinecraftConsoles.git
synced 2026-08-20 09:57:09 +00:00
Revert to original Stronghold
I will keep the infinite world gen base like this so someone else can finish it off. I don't have the necessary skills to recode the entire codebase just for infinite terrain generation + correct structure placement
This commit is contained in:
parent
b608eaf29a
commit
32763937e2
|
|
@ -9,6 +9,7 @@ class TilePos;
|
|||
// 4J Stu - Our default map (at zoom level 3) is 1024x1024 blocks (or 64 chunks)
|
||||
//#define LEVEL_MAX_WIDTH (29999984 / 16) //1,874,999 chunks
|
||||
#define LEVEL_MAX_WIDTH (6 * 64) // Keep renderer sane
|
||||
|
||||
#define LEVEL_WIDTH_CLASSIC 54
|
||||
#define LEVEL_WIDTH_SMALL 64
|
||||
#define LEVEL_WIDTH_MEDIUM (3*64)
|
||||
|
|
|
|||
|
|
@ -33,17 +33,15 @@ void StrongholdFeature::staticCtor()
|
|||
|
||||
void StrongholdFeature::_init()
|
||||
{
|
||||
distance = 32;
|
||||
spread = 3;
|
||||
distance = 32;
|
||||
spread = 3;
|
||||
|
||||
strongholdPos_length = 1;
|
||||
|
||||
for (int i = 0; i < MAX_STRONGHOLDS; i++)
|
||||
{
|
||||
strongholdPos[i] = nullptr;
|
||||
}
|
||||
|
||||
isSpotSelected = false;
|
||||
// 4J added initialisers
|
||||
for (int i = 0; i < strongholdPos_length; i++)
|
||||
{
|
||||
strongholdPos[i] = nullptr;
|
||||
}
|
||||
isSpotSelected = false;
|
||||
}
|
||||
|
||||
StrongholdFeature::StrongholdFeature() : StructureFeature()
|
||||
|
|
@ -91,16 +89,6 @@ bool StrongholdFeature::isFeatureChunk(int x, int z,bool bIsSuperflat)
|
|||
{
|
||||
if (!isSpotSelected)
|
||||
{
|
||||
#ifdef _LARGE_WORLDS
|
||||
if (level->dimension->getXZSize() >= LEVEL_WIDTH_INFINITE)
|
||||
{
|
||||
strongholdPos_length = 128;
|
||||
}
|
||||
else
|
||||
{
|
||||
strongholdPos_length = 1;
|
||||
}
|
||||
#endif
|
||||
Random random;
|
||||
|
||||
random.setSeed(level->getSeed());
|
||||
|
|
|
|||
|
|
@ -29,11 +29,8 @@ private:
|
|||
static vector<Biome *> allowedBiomes;
|
||||
|
||||
bool isSpotSelected;
|
||||
//static const int strongholdPos_length = 1;// Java game has 3, but xbox game only has 1 because of the world size; // 4J added
|
||||
//ChunkPos *strongholdPos[strongholdPos_length];
|
||||
static const int MAX_STRONGHOLDS = 128;
|
||||
ChunkPos *strongholdPos[MAX_STRONGHOLDS];
|
||||
int strongholdPos_length;
|
||||
static const int strongholdPos_length = 1;// Java game has 3, but xbox game only has 1 because of the world size; // 4J added
|
||||
ChunkPos *strongholdPos[strongholdPos_length];
|
||||
double distance;
|
||||
int spread;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue