[1.2.10][1.11.2] NPE Error trying to emulate vanilla decoration
AGSPhoenix opened this issue ยท 5 comments
[23:32:29] [Server thread/ERROR] [reccomplex]: Error trying to emulate vanilla decoration
java.lang.NullPointerException
at net.minecraft.world.gen.feature.WorldGenAbstractTree.isReplaceable(WorldGenAbstractTree.java:37) ~[avz.class:?]
at net.minecraft.world.gen.feature.WorldGenBigTree.func_175936_a(WorldGenBigTree.java:257) ~[awa.class:?]
at net.minecraft.world.gen.feature.WorldGenBigTree.func_76489_a(WorldGenBigTree.java:73) ~[awa.class:?]
at net.minecraft.world.gen.feature.WorldGenBigTree.func_180709_b(WorldGenBigTree.java:290) ~[awa.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.VanillaDecorationAdapter.generate(VanillaDecorationAdapter.java:79) ~[VanillaDecorationAdapter.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.RCBiomeDecorator.doDecorate(RCBiomeDecorator.java:70) ~[RCBiomeDecorator.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.RCBiomeDecorator.decorate(RCBiomeDecorator.java:45) ~[RCBiomeDecorator.class:?]
at ivorius.reccomplex.events.handlers.RCTerrainGenEventHandler.onDecoration(RCTerrainGenEventHandler.java:111) ~[RCTerrainGenEventHandler.class:?]
at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_133_RCTerrainGenEventHandler_onDecoration_Decorate.invoke(.dynamic) ~[?:?]
at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90) ~[ASMEventHandler.class:?]
at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:185) ~[EventBus.class:?]
at net.minecraftforge.event.terraingen.TerrainGen.decorate(TerrainGen.java:61) ~[TerrainGen.class:?]
at net.minecraft.world.biome.BiomeForest.func_185379_b(BiomeForest.java:118) ~[akp.class:?]
at net.minecraft.world.biome.BiomeForest.func_180624_a(BiomeForest.java:85) ~[akp.class:?]
at net.minecraft.world.gen.ChunkProviderOverworld.func_185931_b(ChunkProviderOverworld.java:464) ~[avx.class:?]
at net.minecraft.world.chunk.Chunk.func_186034_a(Chunk.java:1001) ~[auo.class:?]
at net.minecraft.world.chunk.Chunk.func_186030_a(Chunk.java:968) ~[auo.class:?]
at net.minecraft.world.gen.ChunkProviderServer.func_186025_d(ChunkProviderServer.java:158) ~[lv.class:?]
at net.minecraft.world.World.func_72964_e(World.java:303) ~[ajs.class:?]
at net.minecraft.world.World.func_175726_f(World.java:298) ~[ajs.class:?]
at net.minecraft.world.World.func_180495_p(World.java:903) ~[ajs.class:?]
at ivorius.reccomplex.world.gen.feature.structure.generic.WorldCache.getBlockState(WorldCache.java:49) ~[WorldCache.class:?]
at ivorius.reccomplex.world.MockWorld$Cache.getBlockState(MockWorld.java:92) ~[MockWorld$Cache.class:?]
at ivorius.reccomplex.utils.expression.PositionedBlockMatcher$Argument.at(PositionedBlockMatcher.java:68) ~[PositionedBlockMatcher$Argument.class:?]
at ivorius.reccomplex.utils.expression.PositionedBlockMatcher$Argument.at(PositionedBlockMatcher.java:83) ~[PositionedBlockMatcher$Argument.class:?]
at ivorius.reccomplex.world.gen.feature.structure.generic.placement.rays.RayAverageMatcher.lambda$null$611(RayAverageMatcher.java:137) ~[RayAverageMatcher.class:?]
at ivorius.reccomplex.utils.algebra.SupplierCache.get(SupplierCache.java:35) ~[SupplierCache.class:?]
at ivorius.reccomplex.utils.expression.PositionedBlockMatcher$BlocksVariableType.lambda$parse$242(PositionedBlockMatcher.java:196) ~[PositionedBlockMatcher$BlocksVariableType.class:?]
at ivorius.reccomplex.utils.algebra.FunctionExpressionCache.lambda$evaluate$56(FunctionExpressionCache.java:109) ~[FunctionExpressionCache.class:?]
at ivorius.reccomplex.utils.algebra.Algebra$Variable.evaluate(Algebra.java:423) ~[Algebra$Variable.class:?]
at ivorius.reccomplex.utils.algebra.BoolAlgebra$2.evaluate(BoolAlgebra.java:36) ~[BoolAlgebra$2.class:?]
at ivorius.reccomplex.utils.algebra.BoolAlgebra$2.evaluate(BoolAlgebra.java:32) ~[BoolAlgebra$2.class:?]
at ivorius.reccomplex.utils.algebra.Algebras$Infix.evaluate(Algebras.java:82) ~[Algebras$Infix.class:?]
at ivorius.reccomplex.utils.algebra.Algebra$Operation.evaluate(Algebra.java:496) ~[Algebra$Operation.class:?]
at ivorius.reccomplex.utils.algebra.Algebras$Parentheses.evaluate(Algebras.java:47) ~[Algebras$Parentheses.class:?]
at ivorius.reccomplex.utils.algebra.Algebra$Operation.evaluate(Algebra.java:496) ~[Algebra$Operation.class:?]
at ivorius.reccomplex.utils.algebra.BoolAlgebra$3.evaluate(BoolAlgebra.java:48) ~[BoolAlgebra$3.class:?]
at ivorius.reccomplex.utils.algebra.BoolAlgebra$3.evaluate(BoolAlgebra.java:44) ~[BoolAlgebra$3.class:?]
at ivorius.reccomplex.utils.algebra.Algebras$Infix.evaluate(Algebras.java:82) ~[Algebras$Infix.class:?]
at ivorius.reccomplex.utils.algebra.Algebra$Operation.evaluate(Algebra.java:496) ~[Algebra$Operation.class:?]
at ivorius.reccomplex.utils.algebra.FunctionExpressionCache.evaluate(FunctionExpressionCache.java:109) ~[FunctionExpressionCache.class:?]
at ivorius.reccomplex.utils.algebra.FunctionExpressionCache.evaluate(FunctionExpressionCache.java:114) ~[FunctionExpressionCache.class:?]
at ivorius.reccomplex.world.gen.feature.structure.generic.placement.rays.RayAverageMatcher.lambda$cast$612(RayAverageMatcher.java:137) ~[RayAverageMatcher.class:?]
at ivorius.reccomplex.world.gen.feature.structure.generic.placement.rays.RayAverageMatcher.findFirstBlock(RayAverageMatcher.java:61) ~[RayAverageMatcher.class:?]
at ivorius.reccomplex.world.gen.feature.structure.generic.placement.rays.RayAverageMatcher.getAverageGroundLevel(RayAverageMatcher.java:86) ~[RayAverageMatcher.class:?]
at ivorius.reccomplex.world.gen.feature.structure.generic.placement.rays.RayAverageMatcher.cast(RayAverageMatcher.java:136) ~[RayAverageMatcher.class:?]
at ivorius.reccomplex.world.gen.feature.structure.generic.placement.FactorLimit.consider(FactorLimit.java:82) ~[FactorLimit.class:?]
at ivorius.reccomplex.world.gen.feature.structure.generic.placement.GenericPlacer.lambda$place$175(GenericPlacer.java:77) ~[GenericPlacer.class:?]
at java.util.ArrayList.forEach(ArrayList.java:1249) ~[?:1.8.0_131]
at ivorius.reccomplex.world.gen.feature.structure.generic.placement.GenericPlacer.place(GenericPlacer.java:75) ~[GenericPlacer.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.RCBiomeDecorator.lambda$shift$257(RCBiomeDecorator.java:140) ~[RCBiomeDecorator.class:?]
at ivorius.reccomplex.world.gen.feature.StructureGenerator.boundingBox(StructureGenerator.java:327) [StructureGenerator.class:?]
at ivorius.reccomplex.world.gen.feature.StructureGenerator.boundingBox(StructureGenerator.java:300) [StructureGenerator.class:?]
at ivorius.reccomplex.world.gen.feature.StructureGenerator.spawn(StructureGenerator.java:460) [StructureGenerator.class:?]
at ivorius.reccomplex.world.gen.feature.StructureGenerator.generate(StructureGenerator.java:112) [StructureGenerator.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.RCBiomeDecorator.generateSurface(RCBiomeDecorator.java:135) [RCBiomeDecorator.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.RCBiomeDecorator.trySurface(RCBiomeDecorator.java:123) [RCBiomeDecorator.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.RCBiomeDecorator.doDecorate(RCBiomeDecorator.java:107) [RCBiomeDecorator.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.RCBiomeDecorator.doDecorate(RCBiomeDecorator.java:65) [RCBiomeDecorator.class:?]
at ivorius.reccomplex.world.gen.feature.decoration.RCBiomeDecorator.decorate(RCBiomeDecorator.java:45) [RCBiomeDecorator.class:?]
at ivorius.reccomplex.events.handlers.RCTerrainGenEventHandler.onDecoration(RCTerrainGenEventHandler.java:111) [RCTerrainGenEventHandler.class:?]
at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_133_RCTerrainGenEventHandler_onDecoration_Decorate.invoke(.dynamic) [?:?]
at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90) [ASMEventHandler.class:?]
at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:185) [EventBus.class:?]
at net.minecraftforge.event.terraingen.TerrainGen.decorate(TerrainGen.java:61) [TerrainGen.class:?]
at net.minecraft.world.biome.BiomeForest.func_185379_b(BiomeForest.java:118) [akp.class:?]
at net.minecraft.world.biome.BiomeForest.func_180624_a(BiomeForest.java:85) [akp.class:?]
at net.minecraft.world.gen.ChunkProviderOverworld.func_185931_b(ChunkProviderOverworld.java:464) [avx.class:?]
at net.minecraft.world.chunk.Chunk.func_186034_a(Chunk.java:1001) [auo.class:?]
at net.minecraft.world.chunk.Chunk.func_186030_a(Chunk.java:982) [auo.class:?]
at net.minecraftforge.common.chunkio.ChunkIOProvider.syncCallback(ChunkIOProvider.java:105) [ChunkIOProvider.class:?]
at net.minecraftforge.common.chunkio.ChunkIOExecutor.syncChunkLoad(ChunkIOExecutor.java:94) [ChunkIOExecutor.class:?]
at net.minecraft.world.gen.ChunkProviderServer.loadChunk(ChunkProviderServer.java:119) [lv.class:?]
at net.minecraft.world.gen.ChunkProviderServer.func_186028_c(ChunkProviderServer.java:90) [lv.class:?]
at net.minecraft.world.gen.ChunkProviderServer.func_186025_d(ChunkProviderServer.java:136) [lv.class:?]
at net.minecraft.world.World.func_72964_e(World.java:303) [ajs.class:?]
at net.minecraftforge.common.ForgeChunkManager$1.apply(ForgeChunkManager.java:142) [ForgeChunkManager$1.class:?]
at net.minecraftforge.common.ForgeChunkManager$1.apply(ForgeChunkManager.java:137) [ForgeChunkManager$1.class:?]
at com.google.common.collect.Iterators$8.transform(Iterators.java:794) [minecraft_server.1.11.2.jar:?]
at com.google.common.collect.TransformedIterator.next(TransformedIterator.java:48) [minecraft_server.1.11.2.jar:?]
at com.google.common.collect.ImmutableCollection$Builder.addAll(ImmutableCollection.java:301) [minecraft_server.1.11.2.jar:?]
at com.google.common.collect.ImmutableSet$Builder.addAll(ImmutableSet.java:522) [minecraft_server.1.11.2.jar:?]
at net.minecraftforge.common.ForgeChunkManager.getPersistentChunksIterableFor(ForgeChunkManager.java:137) [ForgeChunkManager.class:?]
at net.minecraft.world.World.getPersistentChunkIterable(World.java:3839) [ajs.class:?]
at net.minecraft.world.WorldServer.func_147456_g(WorldServer.java:388) [lw.class:?]
at net.minecraft.world.WorldServer.func_72835_b(WorldServer.java:219) [lw.class:?]
at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:709) [MinecraftServer.class:?]
at net.minecraft.server.dedicated.DedicatedServer.func_71190_q(DedicatedServer.java:384) [lh.class:?]
at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:624) [MinecraftServer.class:?]
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:482) [MinecraftServer.class:?]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_131]
The server keeps running just fine, and inspecting the world in MCEdit, there doesn't seem to be anything wrong with the area aside from a few of the big trees which might have generated with no leaves. Kinda hard to tell with all the regular trees clustered around it.
This error seems really rare. I've only had it happen 4-5 times over 1.6 million chunks generated,
You sure those trees aren't ReC trees (e.g. dead trees)? Because for it to be caused by the error they have be vanilla trees that generated halfway / without leaves as you said. Just making sure.
I still don't know what causes this, besides something not setting a biome property correctly or something. If you can find out what biomes this occurs in I'd be a step further.
Flying around one of the affected areas, it looks like either Forest or Roofed Forest,
They could be. I'm not really familiar with what the mod does; I'm technical support for a friend's server which is running it. They certainly look the part.
I checked every other location in the server log where this happened (5 total) and all but one of them was on the boundary of a Forest and Roofed Forest, with the remaining one being Taiga and Roofed Forest. That seems likely to be significant.
I'm not sure if this is feasible, but this article discusses a method for triggering a heap dump from code. If this is something that would provide you useful information, and you can send me a build, I'll run it and get you the dump.
Otherwise, if there's anything I can do to help you track this down, let me know.
Honestly I still can't really imagine how this happens.
The stack trace line numbers are unusable unfortunately, and thus I don't know for sure if world is null or the block state is null. Either one would be very wrong.
Honestly I can only imagine the block state being null, but that would mean that World would return null for some coordinate's state (or its block), which should never happen.
You are not using lightweight mode, right?