Posted February 5, 201510 yr I have made a block with a custom model (ItemPipe). It work fine except for one problem, the ResourceLocation isn't working. I use this code to render the model: @Override public void renderTileEntityAt(TileEntity tileEntity, double x, double y, double z, float scale) { GL11.glPushMatrix(); GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F); ResourceLocation textures = (new ResourceLocation(Mechanistic.MODID, "textures/blocks/StoneItemPipe.png")); Minecraft.getMinecraft().renderEngine.bindTexture(textures); GL11.glPushMatrix(); GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F); this.model.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F); GL11.glPopMatrix(); GL11.glPopMatrix(); } When I run it, it says there is a missing resource, but I put the resource in the right place: Is there something I'm doing wrong? Thanks in advance.
February 5, 201510 yr Also you may already know this but you should make the resource location a static value in your class. You dont want to be getting the resource location every single render tick I am the author of Draconic Evolution
February 6, 201510 yr Also you may already know this but you should make the resource location a static value in your class. You dont want to be getting the resource location every single render tick Good to know.
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.