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

So I am trying to add elements in the periodic table to Minecraft. For some reason, my tooltip for displaying the information about the element does not display the correct information. The item is ItemElement. The tooltip works for the atomic number, boiling point, and melting point, but not for mass or any of the other values (but i'm most concerned about the mass). I suspect the problem is coming from the items not being added to the NonNullList in the ElementUtil file. What is confusing me is the fact that some work and others don't. Any help would be appreciated!

 

Github:

https://github.com/hamhub7/LabDay

 

ItemElement: https://github.com/hamhub7/LabDay/blob/master/src/main/java/com/hamhub7/labday/item/ItemElement.java

ElementUtil: https://github.com/hamhub7/LabDay/blob/master/src/main/java/com/hamhub7/labday/util/ElementUtil.java

I don't see anything related to tooltips, mass or any other information in your ItemElement class. Are you sure you pushed your latest changes to GitHub?

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

  • Author

I thought i did, but it didn't appear to have worked. Can you help me out with that?

 

  • Author
6 minutes ago, diesieben07 said:

The text "mass" does not appear once in your item class. Where are you trying to add a tooltip for mass? Please link specific lines.

https://github.com/hamhub7/LabDay/blob/master/src/main/java/com/hamhub7/labday/item/ItemElement.java#L78

I think the error is probably somewhere in here though

https://github.com/hamhub7/LabDay/blob/master/src/main/java/com/hamhub7/labday/util/ElementUtil.java#L441

  • Author

the init is called in the main class during the init registry. The problem is the large amount of elements (118) so all the elementutil file does is create lists to store all the data, which is then called by the tooltip and other things in the future. I dont know why the list for weight isn't working, because i almost copied and pasted the boiling/melting point one that works. Is there some sort of problem by using an integer instead of a float?

  • Author

Well that’s a bit embarrassing. That’s the problem. Thanks, and I’ll try to clean up the class

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.