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.

Leaderboard

Popular Content

Showing content with the highest reputation on 12/03/17 in all areas

  1. You're right that the code is a bit convoluted. You'll notice that it only checks for < 0 health if the guiScreenIn parameter is null. It seems that the screen passed in is null when "escaping" from some GUIs and so then this section of code will check if the death GUI should be shown. I guess they do this instead of going back to the parent GUI (the normal thing you do when exiting a GUI) because there is a chance that you died while you had the other inventory up on the screen. The Minecraft#displayGuiScreen() method with GuiGameOver is also called from the NetHandlerPlayClient when it receives a SPacketCombatEvent for ENTITY_DIED in the case where the entity is the player. So I suppose there could be a "race" condition that causes the event to fire twice -- once when client decides player health is < 0 and also when it receives packet from server notifying of the death. However, it is not clear to me that this would happen after pressing the respawn button.
  2. I have made a mod that adds a horse cart to minecraft, everything but this works great; For handling the carts movement, I made the cart always face the horse and move it for the distance inbetween on every update like so; Vec3d moveVec = new Vec3d(this.pulling.posX-this.posX-this.getLookVec().x*offset, this.pulling.posY-this.posY, this.pulling.posZ-this.posZ-this.getLookVec().z*offset); moveVec.x, moveVec.y and moveVec.z are then used in Entity#move. I do this on both client and server, yet the cart stutters on every update tick (every 20 ticks in this case). You can experience this by yourself by attaching a horse to a cart and letting it wander around.

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.