Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

Hi,

 

the textures of my TileEntities are not loading properly. This is the full error:

 

2013-07-03 13:22:44 [WARNING] [Minecraft-Client] Failed to load texture: advancedChests:textures/models/ironChest.png
java.io.FileNotFoundException: advancedChests:textures/models/ironChest.png
at net.minecraft.client.resources.SimpleReloadableResourceManager.func_110536_a(SimpleReloadableResourceManager.java:66)
at net.minecraft.client.renderer.texture.SimpleTexture.func_110551_a(SimpleTexture.java:32)
at net.minecraft.client.renderer.texture.TextureManager.func_110579_a(TextureManager.java:84)
at net.minecraft.client.renderer.texture.TextureManager.func_110577_a(TextureManager.java:41)
at cyclonit.advancedChests.client.ItemAdvancedChestRenderer.render(ItemAdvancedChestRenderer.java:62)
at cyclonit.advancedChests.client.ItemAdvancedChestRenderer.renderItem(ItemAdvancedChestRenderer.java:52)
at net.minecraftforge.client.ForgeHooksClient.renderInventoryItem(ForgeHooksClient.java:146)
at net.minecraft.client.renderer.entity.RenderItem.func_110797_b(RenderItem.java:423)
at net.minecraft.client.gui.GuiIngame.renderInventorySlot(GuiIngame.java:976)
at net.minecraftforge.client.GuiIngameForge.renderHotbar(GuiIngameForge.java:206)
at net.minecraftforge.client.GuiIngameForge.renderGameOverlay(GuiIngameForge.java:141)
at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1014)
at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:930)
at net.minecraft.client.Minecraft.run(Minecraft.java:822)
at net.minecraft.client.main.Main.main(Main.java:93)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at net.minecraft.launchwrapper.Launch.launch(Launch.java:57)
at net.minecraft.launchwrapper.Launch.main(Launch.java:18)

 

This is how I am setting up the ResourceLocations:

 

this.modelTexture = new ResourceLocation(Constants.MODID, "textures/models/" + realName + ".png");

 

Constants.MODID = "advancedChests"

realName = "ironChest"

 

The texture I'd like to load is located in "mcp\src\minecraft\assets\advancedChests\textures\models\ironChest.png"

 

What am I doing wrong?

Make sure that the file structure for your textures is:

src\minecraft\assets\<modname>\textures\blocks/items/etc.

there also should be a pack.mcmeta file in the textures folder for ResourceLocation(domain, filename), though I don't know why, I use the "domain:filename" form instead and things work alright.

 

Also, while Forge /should/ recheck LanguageRegistry stuff after PreInit, it doesn't seem to be doing that in 761, so you need to move all the LanguageRegistry calls in your main mod file to PreInit for the texture loading functions to actually be called. 

 

That fixed all the problems with block and item textures for me, you can see my code at https://github.com/Malorolam/Carbonization

Guis aren't behaving yet for me though.

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.