Dynamic Surroundings

Dynamic Surroundings

51M Downloads

[OpenEye] NPE getting current moon phase factor

OreCruncher opened this issue ยท 1 comments

commented

Mod Version:
1.12.2-3.4.7.2

Forge Version:
14.23.2.2619

java.lang.NullPointerException: 

    at net.minecraft.world.WorldProvider.getCurrentMoonPhaseFactor(WorldProvider.java:438)
    at net.minecraft.world.World.func_130001_d(World.java:1545)
    at org.blockartistry.lib.DiurnalUtils.getMoonPhaseFactor(DiurnalUtils.java:70)
    at org.blockartistry.DynSurround.client.handlers.ExpressionStateHandler$6.update(ExpressionStateHandler.java:113)
    at org.blockartistry.DynSurround.client.handlers.ExpressionStateHandler.process(ExpressionStateHandler.java:515)
    at org.blockartistry.DynSurround.client.handlers.EffectManager.clientTick(EffectManager.java:122)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_0_EffectManager_clientTick_ClientTickEvent.invoke(.dynamic:-1)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:90)
    at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:179)
    at net.minecraftforge.fml.common.FMLCommonHandler.onPreClientTick(FMLCommonHandler.java:343)
    at net.minecraft.client.Minecraft.func_71407_l(Minecraft.java:1706)
    at net.minecraft.client.Minecraft.func_71411_J(Minecraft.java:1096)
    at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:397)
    at net.minecraft.client.main.Main.main(SourceFile:123)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(-2)
    at sun.reflect.NativeMethodAccessorImpl.invoke(-1)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(-1)
    at java.lang.reflect.Method.invoke(-1)
    at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
    at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
commented

Looks like the WorldProvider has a bad reference to the World object. Personally I think this back/forth between the World and WorldProvider is fragile because it leads to stuff like this. :\