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

When a held item is damaged using ItemStack.damageItem() or ItemStack.setItemDamage it does the animation that happens when you change your active item (ie mouse wheel scrolling), and it looks terrible when done continually. Which is huge a problem for me as many of my items make use of damage value for a continually changing variable that i wish to display to the player.

 

Is there any way to stop this animation? I notice on completeing a dig with a tool it doesnt happen.

My mod does the same thing the damage values. solved the animation thing by making it a coremod and editing updateEquipedItem() ("Equipped" was spelled wrong, if i remember correctly) in ItemRenderer.class (not sure if it was in that class, i don't have my laptop with me right now so i can't check). if you find a better way of keeping track of the damage, let me know!

  • Author

I could just make another NBT for all my items that do this and use an IItemRenderer to render the bar. I could display more than one bar or change it's color that way.

 

But then I would have to make an inventory renderer for all of those items, which would suck, maybe not as bad if you can register more than one item renderer for an item. Even then I could just make all my item renders extend a single super that does it... I'll see how well I can get it to work later today.

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.