Не грузятся текстуры

1,087
2
Вообщем. Я взял тестовый GUI (Текстуру). Выставил куда надо. Но блин, текстуры (Вообще все) не грузятся.
Вот куски кода:


public static final ResourceLocation gui = new ResourceLocation("ChromaCraft","textures/gui/chromaticum_generic.png");

public void drawBackground(int p_146278_1_)
{
int k = (this.width - 256) / 2;
int l = (this.height - 168) / 2;
if(currentCategory == null)
{
this.mc.renderEngine.bindTexture(gui);
}
if(currentCategory != null && currentDiscovery == null && currentCategory.specificBookTextures != null)
{
this.mc.renderEngine.bindTexture(currentCategory.specificBookTextures);
}
if(currentCategory != null && currentDiscovery == null && currentCategory.specificBookTextures == null)
{
this.mc.renderEngine.bindTexture(gui);
}
if(currentCategory != null && currentDiscovery != null)
{
if(currentCategory == null || currentCategory.specificBookTextures == null)
this.mc.renderEngine.bindTexture(gui);
else
this.mc.renderEngine.bindTexture(currentCategory.specificBookTextures);
}
this.drawTexturedModalRect(k, l, 0, 0, 256, 180);
}
@Override
public void drawScreen(int p_73863_1_, int p_73863_2_, float p_73863_3_)
{
int k = (this.width - 256) / 2;
int l = (this.height - 168) / 2;
try
{
}catch(Exception e)
{
e.printStackTrace();return;
}
int dWheel = Mouse.getDWheel();
if(currentDiscovery != null)
{
if(dWheel < 0)
{
if(this.buttonList.size() > 1)
{
GuiButton button = (GuiButton) this.buttonList.get(2);
if(button.enabled)
this.actionPerformed(button);
}
}
if(dWheel > 0)
{
if(this.buttonList.size() > 1)
{
GuiButton button = (GuiButton) this.buttonList.get(1);
if(button.enabled)
this.actionPerformed(button);
}
}
}else
{
if(currentCategory != null)
{
if(dWheel < 0)
{
if(this.buttonList.size() > 1)
{
GuiButton button = (GuiButton) this.buttonList.get(2);
if(button.enabled)
this.actionPerformed(button);
}
}
if(dWheel > 0)
{
if(this.buttonList.size() > 1)
{
GuiButton button = (GuiButton) this.buttonList.get(1);
if(button.enabled)
this.actionPerformed(button);
}
}
}
}
if(isRightMouseKeyPressed && !Mouse.isButtonDown(1))
{
isRightMouseKeyPressed = false;
}
if(!isRightMouseKeyPressed && Mouse.isButtonDown(1))
{
isRightMouseKeyPressed = true;
if(!prevState.isEmpty())
{
Object[] tryArray = prevState.get(prevState.size()-1);
currentPage = Integer.parseInt(tryArray[1].toString());
currentPage_discovery = Integer.parseInt(tryArray[2].toString());
currentDiscovery = (DiscoveryEntry) tryArray[0];
prevState.remove(prevState.size()-1);
this.initGui();
}
}
if(isLeftMouseKeyPressed && !Mouse.isButtonDown(0))
isLeftMouseKeyPressed = false;
if(FMLClientHandler.instance().getCurrentLanguage().equalsIgnoreCase("en_gb") && !firstOpened)
{
firstOpened = true;
this.fontRendererObj = new FontRenderer(mc.gameSettings, new ResourceLocation("ChromaCraft","textures/special/research_font.png"), mc.renderEngine, false);
fontRendererObj.setUnicodeFlag(false);
fontRendererObj.setBidiFlag(true);
((IReloadableResourceManager)this.mc.getResourceManager()).registerReloadListener(fontRendererObj);
}
hoveringText.clear();
drawBackground(16);
if(currentCategory == null)
{
drawCategories(p_73863_1_, p_73863_2_);
}
if(currentCategory != null && currentDiscovery == null)
{
drawDiscoveries(p_73863_1_,p_73863_2_);
}
if(currentCategory != null && currentDiscovery != null)
{
drawPage(p_73863_1_,p_73863_2_);
}
drawAllText();
if(!this.numberString.isEmpty())
{
RenderHelper.disableStandardItemLighting();
RenderHelper.enableGUIStandardItemLighting();
GL11.glTranslated(0, 0, 100);
GL11.glColor3f(1/(float)(5F-(float)pressDelay), 1/(float)(5F-(float)pressDelay), 1/(float)(5F-(float)pressDelay));
this.drawCenteredString(fontRendererObj, numberString, k+128, l+172, 0xffffff);
GL11.glColor3f(1, 1, 1);
GL11.glTranslated(0, 0, -100);
RenderHelper.enableStandardItemLighting();
}
}

//Ухтыжлол, я не знал, что если копировать что то из IntelliJ IDEA то всё будет как в нём

Сама проблема в том, что вот:
yRolhsi.png

А вот, что в консоли:
[13:59:49] [Client thread/WARN]: Failed to load texture: ChromaCraft:textures/gui/chromaticum_generic.png
java.io.FileNotFoundException: ChromaCraft:textures/gui/chromaticum_generic.png
at net.minecraft.client.resources.SimpleReloadableResourceManager.getResource(SimpleReloadableResourceManager.java:71) ~[SimpleReloadableResourceManager.class:?]
at net.minecraft.client.renderer.texture.SimpleTexture.loadTexture(SimpleTexture.java:35) ~[SimpleTexture.class:?]
at net.minecraft.client.renderer.texture.TextureManager.loadTexture(TextureManager.java:89) [TextureManager.class:?]
at net.minecraft.client.renderer.texture.TextureManager.bindTexture(TextureManager.java:45) [TextureManager.class:?]
at ChromaCraft.client.gui.GuiChromaticum.drawBackground(GuiChromaticum.java:187) [GuiChromaticum.class:?]
at ChromaCraft.client.gui.GuiChromaticum.drawScreen(GuiChromaticum.java:291) [GuiChromaticum.class:?]
at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1137) [EntityRenderer.class:?]
at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1067) [Minecraft.class:?]
at net.minecraft.client.Minecraft.run(Minecraft.java:962) [Minecraft.class:?]
at net.minecraft.client.main.Main.main(Main.java:164) [Main.class:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_66]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_66]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_66]
at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_66]
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
at net.minecraftforge.gradle.GradleStartCommon.launch(Unknown Source) [start/:?]
at GradleStart.main(Unknown Source) [start/:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_66]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_66]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_66]
at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_66]
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:144) [idea_rt.jar:?]
 
Назад
Сверху