Posted March 3, 201411 yr So I've used ISBRH to render my block. Is it possible to use a vanilla model of the stairs for my block for inventory rendering, or do I have to write the rendering code from scratch? Background: I'm overriding the rendering behavior of stairs to connect glass panes to them. In case it's not obvious, I'm not quite familiar with how minecraft renders inventory items.
March 3, 201411 yr Author Ok, I figured out how to render it: renderer.renderBlockAsItem(block, metadata, modelId); (of course I'm swapping out modelId so I don't form a recursive loop of doom). Only problem now is that the block renders in completely flat light. Looks like all other blocks have a light source above them. Mine is now entirely bright and looks flat... see screenshot below... Anyone know how to get this shadow effect so it doesn't look like crap?
March 3, 201411 yr Are you making a custom block or overriding vanilla stairs? Because if you're making your stairs, you could just extend BlockStair, I don't see why having a custom renderer for stairs. I try my best, so apologies if I said something obviously stupid!
March 3, 201411 yr Author Overriding vanilla stairs. Fixed it by locating the tesselator code in RenderBlock (renderBlockAsItem for anyone looking for this in the future) and just copying into my instance of ISBRH. Note that just calling renderBlockAsItem didn't work.... the light level was too flat.
March 4, 201411 yr Hi Minecraft uses a couple of settings for lighting items. Try calling RenderHelper.enableGUIStandardItemLighting(); or RenderHelper.enableStandardItemLighting(); -TGG
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.