Posted October 27, 20159 yr So, I'm updating the mod I've been working on to 1.8, but the RenderBlocks class that I used to render... blocks... into a custom GUI no longer exists. I switched to using RenderItem renderItemModel(ItemStack). It renders items fine, but it only renders blocks registered within my mod. They all run off the same renderItemModel, leading me to believe there is another function I can use for blocks. But, I have yet to find it... Any ideas? :L GL11.glPushMatrix(); { GL11.glTranslatef(x, y, 0F); GL11.glScalef(20F * scale, 20F * scale, 1F); GL11.glTranslatef(.55F, .7F, 1F); GL11.glRotatef(180F, 1F, 0F, 0F); if(spin) if(itemStack.getItem() instanceof ItemBlock) { GL11.glRotatef(20F, 1F, 0F, 0F); GL11.glRotatef(Minecraft.getMinecraft().theWorld.getTotalWorldTime() % 360, 0F, 1F, 0F); }else GL11.glTranslatef(0F, (float)Math.sin(Minecraft.getMinecraft().theWorld.getTotalWorldTime() / 20F) * .1F, 0F); renderItem.renderItemModel(itemStack); } GL11.glPopMatrix();
October 27, 20159 yr Take a look at GuiContainer and look at the drawItemStack method. It should have you covered.
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.