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

I am having a bit of trouble with a custom renderer and i am hoping someone can tell me what i am doing wrong because i have been messing with it for ages and just cant get it to work properly.

 

I am trying to use the renderer for a mob and use it for an item and it is working perfectly except for one thing... Lighting. As an item entity in the world or equipped third person it works fine but in inventory it messes with the games lighting. Specifically it makes everything darker and if you go into light level 0 almost everything is just black even things like the f3 text is to dark to read.

 

This is the item renderer class.

https://github.com/brandon3055/Draconic-Evolution/blob/master/src/main/java/com/brandon3055/draconicevolution/client/render/SoulItemRenderer.java

You can also find the rest of the mod in that repo if there is anything else you need to see.

 

I would really appreciate any help anyone can give me because i have been messing with this for a while but i just dont know enough about rendering.

I am the author of Draconic Evolution

Hi

 

Try wrapping your rendering code in this

 

      GL11.glPushAttrib(GL11.GL_ENABLE_BIT);

// render here

GL11.glPopAttrib();

 

This will save & restore the state of most of the lighting settings.

 

If that doesn't work, you could try putting

RenderHelper.enableStandardItemLighting();

after your render (not before)

 

-TGG

 

  • Author

Hi

 

Try wrapping your rendering code in this

 

      GL11.glPushAttrib(GL11.GL_ENABLE_BIT);

// render here

GL11.glPopAttrib();

 

This will save & restore the state of most of the lighting settings.

 

If that doesn't work, you could try putting

RenderHelper.enableStandardItemLighting();

after your render (not before)

 

-TGG

 

 

THANK YOU!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

I am the author of Draconic Evolution

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.