Skip to content

Commit 1b40f0a

Browse files
author
MrTrollNugNug(Cazsius)
committed
Ported to 1.11.2 (Something went wierd before?)
1 parent 0d71d0b commit 1b40f0a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/main/java/mmd/orespawn/EventHandler.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,14 @@ public void generateChunk(WorldServer world, Chunk chunk) {
6161
Random random = new Random(worldSeed);
6262
long xSeed = random.nextLong() >> 2 + 1L;
6363
long zSeed = random.nextLong() >> 2 + 1L;
64-
long chunkSeed = (xSeed * chunk.xPosition + zSeed * chunk.zPosition) ^ worldSeed;
64+
long chunkSeed = (xSeed * chunk.x + zSeed * chunk.z) ^ worldSeed;
6565

6666
ChunkProviderServer chunkProvider = world.getChunkProvider();
6767
IChunkGenerator chunkGenerator = chunkProvider.chunkGenerator;
6868

6969
for (OreSpawnWorldGenerator generator : entry.getValue()) {
7070
random.setSeed(chunkSeed);
71-
generator.generate(random, chunk.xPosition, chunk.zPosition, world, chunkGenerator, chunkProvider);
71+
generator.generate(random, chunk.x, chunk.z, world, chunkGenerator, chunkProvider);
7272
}
7373

7474
dataList.appendTag(new NBTTagString(entry.getKey()));

src/main/java/mmd/orespawn/world/OreSpawnData.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ public NBTTagCompound writeToNBT(NBTTagCompound compound) {
4242
for (Map.Entry<ChunkPos, NBTTagList> entry : this.chunkData.entrySet()) {
4343
NBTTagCompound data = new NBTTagCompound();
4444

45-
data.setInteger("ChunkX", entry.getKey().chunkXPos);
46-
data.setInteger("ChunkZ", entry.getKey().chunkZPos);
45+
data.setInteger("ChunkX", entry.getKey().x);
46+
data.setInteger("ChunkZ", entry.getKey().z);
4747
data.setTag("GeneratedIDs", entry.getValue());
4848

4949
list.appendTag(data);

0 commit comments

Comments
 (0)