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

hi

 

to be more specific i want a helmet to light up the surrounding area like a torch when it is equipped but i cant find any onEquip functions. was looking for an event method also but couldnt find anything.

 

any help is appreciated thanks

i am not sure if there is player update event, else use entity update , check if its a player, than check if he has the armor equipped, thatn ligt up area

Armour have method onArmorTick - called when you are wearing armour. (inside your armour class, override it).

 

For vanilla armour - indeed - PlayerTickEvent or LivingUpdateEvent, check eq and do stuff.

1.7.10 is no longer supported by forge, you are on your own.

This is assuming that you'd be changing the light level of the block where the player's head is. What you could do is save the player's last x, y, and z location somehow and on every armor tick, compare that to the player's current location. If that has changed, set the old location's light level to 0 and the new location to 15.

 

It's also worth noting that doing several light updates a second could be problematic.

I like trains.

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.