Posted November 21, 201311 yr Hey, I created a BlockContainer, a Container and a TileEntyity for it, made a GuiContaier and a custom gui handler. Now, when I right click my block, it errors and shuts down the game. java.lang.NullPointerException 2013-11-21 17:42:15 [iNFO] [sTDOUT] at cpw.mods.fml.common.network.NetworkRegistry.openLocalGui(NetworkRegistry.java:328) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at cpw.mods.fml.common.network.FMLNetworkHandler.openGui(FMLNetworkHandler.java:357) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at mods.makerimages.ElectronicaE.blocks.BlockGrinder.onBlockActivated(BlockGrinder.java:43) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at net.minecraft.client.multiplayer.PlayerControllerMP.onPlayerRightClick(PlayerControllerMP.java:371) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at net.minecraft.client.Minecraft.clickMouse(Minecraft.java:1390) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at net.minecraft.client.Minecraft.runTick(Minecraft.java:1868) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:910) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at net.minecraft.client.Minecraft.run(Minecraft.java:838) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at net.minecraft.client.main.Main.main(Main.java:93) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at java.lang.reflect.Method.invoke(Unknown Source) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at net.minecraft.launchwrapper.Launch.launch(Launch.java:131) 2013-11-21 17:42:15 [iNFO] [sTDOUT] at net.minecraft.launchwrapper.Launch.main(Launch.java:27) Look at the sources here: https://bitbucket.org/makerimages/electronica-engineered commit is d82bb6a right now (project readme is messed, dont look at it) How could I fix saisd nullpointer
November 21, 201311 yr Nope... sorry, I just spotted you alredy gave your code... looking at it now... 1.7.10 is no longer supported by forge, you are on your own.
November 22, 201311 yr Author Wait.. actually, I was not initializing it at all. fixed it, works now!
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.