![Gadgetry: Machines](https://media.forgecdn.net/avatars/thumbnails/132/499/256/256/636475780477384385.png)
Multiple crashes using Energy Cell and Energy pipes.
DrUltraLux opened this issue ยท 2 comments
I am getting frequent crashes when attempting to get energy systems working. Also seems to frequently just stop transferring energy into the network.
Also often have to delete the config file after a crash or forge black screens.
Found one of the problems.
[Netty Server IO #1/ERROR]: There was a critical exception handling a packet on channel gadgetrycore
io.netty.handler.codec.EncoderException: java.lang.RuntimeException: Undefined discriminator for message type epicsquid.gadgetry.core.network.MessageTEUpdate in channel gadgetrycore
at io.netty.handler.codec.MessageToMessageEncoder.write(MessageToMessageEncoder.java:106) ~[MessageToMessageEncoder.class:4.1.9.Final]
at io.netty.handler.codec.MessageToMessageCodec.write(MessageToMessageCodec.java:116) ~[MessageToMessageCodec.class:4.1.9.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:738) ~[AbstractChannelHandlerContext.class:4.1.9.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeWriteAndFlush(AbstractChannelHandlerContext.java:801) ~[AbstractChannelHandlerContext.class:4.1.9.Final]
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:814) ~[AbstractChannelHandlerContext.class:4.1.9.Final]
at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:794) ~[AbstractChannelHandlerContext.class:4.1.9.Final]
at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:831) ~[AbstractChannelHandlerContext.class:4.1.9.Final]
at io.netty.channel.DefaultChannelPipeline.writeAndFlush(DefaultChannelPipeline.java:1032) ~[DefaultChannelPipeline.class:4.1.9.Final]
at io.netty.channel.AbstractChannel.writeAndFlush(AbstractChannel.java:296) ~[AbstractChannel.class:4.1.9.Final]
at net.minecraftforge.fml.common.network.simpleimpl.SimpleNetworkWrapper.sendToAll(SimpleNetworkWrapper.java:236) ~[SimpleNetworkWrapper.class:?]
at epicsquid.gadgetry.core.EventManager.onServerTick(EventManager.java:81) ~[EventManager.class:?]
at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_2025_EventManager_onServerTick_WorldTickEvent.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.fml.common.FMLCommonHandler.onPostWorldTick(FMLCommonHandler.java:274) ~[FMLCommonHandler.class:?]
at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:776) ~[MinecraftServer.class:?]
at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:668) ~[MinecraftServer.class:?]
at net.minecraft.server.integrated.IntegratedServer.func_71217_p(IntegratedServer.java:185) ~[chd.class:?]
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:526) ~[MinecraftServer.class:?]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_51]
Caused by: java.lang.RuntimeException: Undefined discriminator for message type epicsquid.gadgetry.core.network.MessageTEUpdate in channel gadgetrycore
at net.minecraftforge.fml.common.network.FMLIndexedMessageToMessageCodec.encode(FMLIndexedMessageToMessageCodec.java:76) ~[FMLIndexedMessageToMessageCodec.class:?]
at io.netty.handler.codec.MessageToMessageCodec$1.encode(MessageToMessageCodec.java:67) ~[MessageToMessageCodec$1.class:4.1.9.Final]
at io.netty.handler.codec.MessageToMessageEncoder.write(MessageToMessageEncoder.java:88) ~[MessageToMessageEncoder.class:4.1.9.Final]
... 19 more
Problem is here.
Sometimes it is attempting to write a Null tag to the ByteBuff.
Should put an if(tag) or try() around the buffer write.