Made Wild Plants not generate on Mycelium and plop off right away

This commit is contained in:
Ellpeck 2015-11-19 18:35:09 +01:00
parent 11e2326cae
commit badfe60805

View file

@ -86,7 +86,7 @@ public class WorldDecorationEvent{
int genZ = event.chunkZ+event.rand.nextInt(16)+8; int genZ = event.chunkZ+event.rand.nextInt(16)+8;
int genY = event.world.getTopSolidOrLiquidBlock(genX, genZ)-1; int genY = event.world.getTopSolidOrLiquidBlock(genX, genZ)-1;
if(event.world.getBlock(genX, genY, genZ).getMaterial() == blockBelow){ if(event.world.getBlock(genX, genY, genZ).getMaterial() == blockBelow && plant.canBlockStay(event.world, genX, genY+1, genZ)){
event.world.setBlock(genX, genY+1, genZ, plant, meta, 2); event.world.setBlock(genX, genY+1, genZ, plant, meta, 2);
} }
} }