Fixed end flowers crashing when being spawned

Closes #73
This commit is contained in:
Ellpeck 2020-01-30 13:45:19 +01:00
parent 00ab016498
commit 26a41c5055
3 changed files with 5 additions and 5 deletions

View file

@ -30,7 +30,7 @@ minecraft {
property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'
// Recommended logging level for the console // Recommended logging level for the console
property 'forge.logging.console.level', 'debug' property 'forge.logging.console.level', 'info'
mods { mods {
naturesaura { naturesaura {
@ -46,7 +46,7 @@ minecraft {
property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'
// Recommended logging level for the console // Recommended logging level for the console
property 'forge.logging.console.level', 'debug' property 'forge.logging.console.level', 'info'
mods { mods {
naturesaura { naturesaura {
@ -62,7 +62,7 @@ minecraft {
property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP'
// Recommended logging level for the console // Recommended logging level for the console
property 'forge.logging.console.level', 'debug' property 'forge.logging.console.level', 'info'
args '--mod', 'naturesaura', '--all', '--output', file('src/generated/resources/') args '--mod', 'naturesaura', '--all', '--output', file('src/generated/resources/')

View file

@ -129,7 +129,7 @@ public class BlockDimensionRail extends AbstractRailBlock implements IModItem, I
World overworld = server.getWorld(goalDimType); World overworld = server.getWorld(goalDimType);
BlockPos spawn = overworld.getSpawnPoint(); BlockPos spawn = overworld.getSpawnPoint();
BlockPos ret = new BlockPos(spawn.getX(), 0, spawn.getZ()); BlockPos ret = new BlockPos(spawn.getX(), 0, spawn.getZ());
return ret.up(overworld.getHeight(Heightmap.Type.WORLD_SURFACE_WG, spawn.getX(), spawn.getZ())); return ret.up(overworld.getHeight(Heightmap.Type.WORLD_SURFACE, spawn.getX(), spawn.getZ()));
} }
} }
} }

View file

@ -60,7 +60,7 @@ public class BlockEndFlower extends BushBlock implements IModItem, IModelProvide
for (int i = 0; i < 6; i++) { for (int i = 0; i < 6; i++) {
int x = dragon.world.rand.nextInt(256) - 128; int x = dragon.world.rand.nextInt(256) - 128;
int z = dragon.world.rand.nextInt(256) - 128; int z = dragon.world.rand.nextInt(256) - 128;
BlockPos pos = new BlockPos(x, dragon.world.getHeight(Heightmap.Type.WORLD_SURFACE_WG, x, z), z); BlockPos pos = new BlockPos(x, dragon.world.getHeight(Heightmap.Type.WORLD_SURFACE, x, z), z);
if (!dragon.world.isBlockLoaded(pos)) if (!dragon.world.isBlockLoaded(pos))
continue; continue;
if (dragon.world.getBlockState(pos.down()).getBlock() != Blocks.END_STONE) if (dragon.world.getBlockState(pos.down()).getBlock() != Blocks.END_STONE)