Jump to content

Recommended Posts

Posted

Registering an icon, you need to pass in a string, which I assume is the path to the texture. How do you format the path?

I divide my mod into packages of similar functions, so that my textures are at mod folder/planetguy/Gizmos/spy for example.

Posted

Thanks for telling me, I found it here. Another thing, I have a persistent error:


2013-03-24 09:29:11 [iNFO] [sTDERR] java.lang.RuntimeException: Don't register null!

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.renderer.texture.TextureMap.registerIcon(TextureMap.java:229)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.item.Item.updateIcons(Item.java:726)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.renderer.texture.TextureMap.refreshTextures(TextureMap.java:85)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.renderer.RenderEngine.refreshTextureMaps(RenderEngine.java:521)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.renderer.RenderEngine.refreshTextures(RenderEngine.java:432)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at cpw.mods.fml.client.FMLClientHandler.onInitializationComplete(FMLClientHandler.java:247)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.Minecraft.startGame(Minecraft.java:475)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.MinecraftAppletImpl.startGame(MinecraftAppletImpl.java:44)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.Minecraft.run(Minecraft.java:729)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at java.lang.Thread.run(Thread.java:722)

2013-03-24 09:29:11 [iNFO] [sTDERR] java.lang.NullPointerException

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.renderer.texture.TextureMap.refreshTextures(TextureMap.java:102)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.renderer.RenderEngine.refreshTextureMaps(RenderEngine.java:521)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.renderer.RenderEngine.refreshTextures(RenderEngine.java:432)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at cpw.mods.fml.client.FMLClientHandler.onInitializationComplete(FMLClientHandler.java:247)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.Minecraft.startGame(Minecraft.java:475)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.MinecraftAppletImpl.startGame(MinecraftAppletImpl.java:44)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at net.minecraft.client.Minecraft.run(Minecraft.java:729)

2013-03-24 09:29:11 [iNFO] [sTDERR]    at java.lang.Thread.run(Thread.java:722)

Edit: I narrowed it down to the spy table part, which is probably not working because it contains a GUI screen. Anyone know what needs to be done to GUIs to fix texture loading in 1.5?

Posted

Should be no depreciatable change to how GUI art is coded in, AFAIK. The way they arranged the texture directory after I used Unsticher on a pre 1.5 texture pack says that they go into a GUI folder.

Posted

That's weird... You're registering a possible runtime exception (with the code I gave you) but it is null?? The code should work.

If it hasn't got anything to do with that config stuff, idk...

Posted

I found it! I never gave the spy lens item (an ingredient for the spy lab) an unlocalized name, so it was null.

Ahh, yeah... That is indeed problematic. (well, not anymore :P)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...