mirror of
https://github.com/Cubitect/cubiomes.git
synced 2025-09-23 11:45:27 -04:00
Fix broken end gateway gen for pre 1.18
This commit is contained in:
parent
761b876b2f
commit
91ba293616
@ -170,7 +170,7 @@ int getStructureConfig(int structureType, int mc, StructureConfig *sconf)
|
||||
*sconf = BASTION_CONFIG;
|
||||
return mc >= MC_1_16;
|
||||
case End_Gateway:
|
||||
*sconf = END_GATEWAY_CONFIG;
|
||||
*sconf = mc <= MC_1_15 ? END_GATEWAY_CONFIG_115 : END_GATEWAY_CONFIG;
|
||||
return mc >= MC_1_13;
|
||||
default:
|
||||
memset(sconf, 0, sizeof(StructureConfig));
|
||||
@ -281,13 +281,12 @@ int getStructurePos(int structureType, int mc, uint64_t seed, int regX, int regZ
|
||||
}
|
||||
else
|
||||
{
|
||||
seed = getPopulationSeed(mc, seed, pos->x, pos->z);
|
||||
setSeed(&seed, seed + sconf.salt);
|
||||
if (mc <= MC_1_16) {
|
||||
if (nextInt(&seed, 700) != 0)
|
||||
if (mc >= MC_1_17) {
|
||||
if (nextFloat(&seed) >= 1.0/700)
|
||||
return 0;
|
||||
} else {
|
||||
if (nextFloat(&seed) >= 1.0/700)
|
||||
if (nextInt(&seed, 700) != 0)
|
||||
return 0;
|
||||
}
|
||||
pos->x += nextInt(&seed, 16);
|
||||
|
@ -111,6 +111,7 @@ _sc BASTION_CONFIG = { 30084232, 27, 23, Bastion, 0};
|
||||
_sc END_CITY_CONFIG = { 10387313, 20, 9, End_City, LARGE_STRUCT};
|
||||
|
||||
// for the scattered return gateways
|
||||
_sc END_GATEWAY_CONFIG_115 = { 30000, 1, 1, End_Gateway, CHUNK_STRUCT};
|
||||
_sc END_GATEWAY_CONFIG = { 40013, 1, 1, End_Gateway, CHUNK_STRUCT};
|
||||
|
||||
#undef _sc
|
||||
|
Loading…
x
Reference in New Issue
Block a user