cleverpanda / SimpleCorn

Corn Like Mojang might add
6 stars 5 forks source link

[2.4.1] Exception when feeding corn to animals #28

Closed Insane96 closed 5 years ago

Insane96 commented 5 years ago

I don't know if still happens in 2.5+ because happened on server which has older version.

[04:16:35] [Server thread/ERROR] [FML]: Exception caught during firing event net.minecraftforge.event.entity.player.PlayerInteractEvent$EntityInteract@5d9d23e0:
java.lang.NullPointerException: The validated object is null
    at org.apache.commons.lang3.Validate.notNull(Validate.java:225) ~[minecraft_server.1.12.2.jar:?]
    at org.apache.commons.lang3.Validate.notNull(Validate.java:206) ~[minecraft_server.1.12.2.jar:?]
    at net.minecraft.util.NonNullList.set(SourceFile:49) ~[fi.class:?]
    at net.minecraft.entity.player.InventoryPlayer.func_70299_a(InventoryPlayer.java:575) ~[aec.class:?]
    at panda.corn.events.GenericBreedHandler.breed(GenericBreedHandler.java:40) ~[GenericBreedHandler.class:?]
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_301_GenericBreedHandler_breed_EntityInteract.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:182) [EventBus.class:?]
    at net.minecraftforge.common.ForgeHooks.onInteractEntity(ForgeHooks.java:1111) [ForgeHooks.class:?]
    at net.minecraft.entity.player.EntityPlayer.func_190775_a(EntityPlayer.java:1194) [aed.class:?]
    at net.minecraft.network.NetHandlerPlayServer.func_147340_a(NetHandlerPlayServer.java:1073) [pa.class:?]
    at net.minecraft.network.play.client.CPacketUseEntity.func_148833_a(SourceFile:69) [li.class:?]
    at net.minecraft.network.play.client.CPacketUseEntity.func_148833_a(SourceFile:13) [li.class:?]
    at net.minecraft.network.PacketThreadUtil$1.run(SourceFile:13) [hv$1.class:?]
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_111]
    at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_111]
    at net.minecraft.util.Util.func_181617_a(SourceFile:46) [h.class:?]
    at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:723) [MinecraftServer.class:?]
    at net.minecraft.server.dedicated.DedicatedServer.func_71190_q(DedicatedServer.java:397) [nz.class:?]
    at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:668) [MinecraftServer.class:?]
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:526) [MinecraftServer.class:?]
    at java.lang.Thread.run(Thread.java:745) [?:1.8.0_111]
[04:16:35] [Server thread/ERROR] [FML]: Index: 8 Listeners:
[04:16:35] [Server thread/ERROR] [FML]: 0: NORMAL
[04:16:35] [Server thread/ERROR] [FML]: 1: ASM: crafttweaker.mc1120.events.CommonEventHandler@76c6f774 onPlayerInteractEntity(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 2: ASM: vazkii.quark.misc.feature.SlimeBucket@282d3a5b entityInteract(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 3: ASM: vazkii.quark.misc.feature.PoisonPotatoUsage@2e538e3c onInteract(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 4: ASM: vazkii.quark.misc.feature.ParrotEggs@15426bef entityInteract(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 5: ASM: vazkii.quark.tweaks.feature.ShearableChickens@65584db3 onEntityInteract(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 6: ASM: vazkii.quark.tweaks.feature.MinecartInteraction@4ec92b36 onEntityInteract(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 7: ASM: panda.corn.events.GenericBreedHandler@6db2ca3 breed(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 8: ASM: panda.corn.events.GenericBreedHandler@6aec68d7 breed(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 9: ASM: com.bloodnbonesgaming.triumph.events.TEventHandler@74d65237 onRightClickEntity(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 10: ASM: iguanaman.hungeroverhaul.module.event.HungerOverhaulEventHook@2e5524cf onEntityInteractEvent(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent$EntityInteract;)V
[04:16:35] [Server thread/ERROR] [FML]: 11: ASM: crafttweaker.mc1120.events.CommonEventHandler@76c6f774 onPlayerInteract(Lnet/minecraftforge/event/entity/player/PlayerInteractEvent;)V
[04:16:35] [Server thread/ERROR] [FML]: 12: ASM: com.buuz135.togetherforever.action.AdvancementEventSyncAction@57cc0c19 onEvent(Lnet/minecraftforge/event/entity/player/PlayerEvent;)V
[04:16:35] [Server thread/FATAL] [minecraft/MinecraftServer]: Error executing task
java.util.concurrent.ExecutionException: java.lang.NullPointerException: The validated object is null
    at java.util.concurrent.FutureTask.report(FutureTask.java:122) ~[?:1.8.0_111]
    at java.util.concurrent.FutureTask.get(FutureTask.java:192) ~[?:1.8.0_111]
    at net.minecraft.util.Util.func_181617_a(SourceFile:47) [h.class:?]
    at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:723) [MinecraftServer.class:?]
    at net.minecraft.server.dedicated.DedicatedServer.func_71190_q(DedicatedServer.java:397) [nz.class:?]
    at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:668) [MinecraftServer.class:?]
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:526) [MinecraftServer.class:?]
    at java.lang.Thread.run(Thread.java:745) [?:1.8.0_111]
Caused by: java.lang.NullPointerException: The validated object is null
    at org.apache.commons.lang3.Validate.notNull(Validate.java:225) ~[minecraft_server.1.12.2.jar:?]
    at org.apache.commons.lang3.Validate.notNull(Validate.java:206) ~[minecraft_server.1.12.2.jar:?]
    at net.minecraft.util.NonNullList.set(SourceFile:49) ~[fi.class:?]
    at net.minecraft.entity.player.InventoryPlayer.func_70299_a(InventoryPlayer.java:575) ~[aec.class:?]
    at panda.corn.events.GenericBreedHandler.breed(GenericBreedHandler.java:40) ~[GenericBreedHandler.class:?]
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_301_GenericBreedHandler_breed_EntityInteract.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:182) ~[EventBus.class:?]
    at net.minecraftforge.common.ForgeHooks.onInteractEntity(ForgeHooks.java:1111) ~[ForgeHooks.class:?]
    at net.minecraft.entity.player.EntityPlayer.func_190775_a(EntityPlayer.java:1194) ~[aed.class:?]
    at net.minecraft.network.NetHandlerPlayServer.func_147340_a(NetHandlerPlayServer.java:1073) ~[pa.class:?]
    at net.minecraft.network.play.client.CPacketUseEntity.func_148833_a(SourceFile:69) ~[li.class:?]
    at net.minecraft.network.play.client.CPacketUseEntity.func_148833_a(SourceFile:13) ~[li.class:?]
    at net.minecraft.network.PacketThreadUtil$1.run(SourceFile:13) ~[hv$1.class:?]
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:1.8.0_111]
    at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_111]
    at net.minecraft.util.Util.func_181617_a(SourceFile:46) ~[h.class:?]
    ... 5 more
Insane96 commented 5 years ago

Now that I notice might be fixed in 2.5+ https://github.com/cleverpanda/SimpleCorn/blob/1.12/src/main/java/panda/corn/events/GenericBreedHandler.java#L40