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

Hello,

 

I've been trying to make an entity made of multiple parts, therefore it can have multiple hitboxes. However, the problem is that I can't see the hitboxes by pressing f3 + B. I saw a post (http://www.minecraftforge.net/forum/index.php/topic,6258.0.html) with code making them visible, but I can't place it anywhere in my mod properly. So, where do I need to put this code, or is there an easier way now?

Well, the code you referenced here is outdated. It is replaced by a much shorter version, which you can see at

renderDebugBoundingBox(...)

in the class described there. These lines right around here:

float f2 = p_85094_1_.width / 2.0F;
AxisAlignedBB axisalignedbb = AxisAlignedBB.getBoundingBox(p_85094_2_ - (double)f2, p_85094_4_, p_85094_6_ - (double)f2, p_85094_2_ + (double)f2, p_85094_4_ + (double)p_85094_1_.height, p_85094_6_ + (double)f2);
RenderGlobal.drawOutlinedBoundingBox(axisalignedbb, 16777215);

 

You now can repeat that code inside a for loop for each of the entity's parts, as shown in your thread. The entity you need is the first argument passed to this method.

 

You cannot put it in this method, so you have to copy the code and put ut in for example your main entity renderig method.

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.