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

I have downloaded a mod and the items and blocks of the mod come with descriptions. Instead of just the name of the item, you can also read a short description about it in a darker shade of gray.

 

I think that's very useful. I was wondering if that's a feature of that mod in specific or if it's something we can do easily, like having our item/block implement an interface, or something related to the LanguageRegistry or maybe some other registry. Thanks.

Items have a method called addInformation which you can use.

If you guys dont get it.. then well ya.. try harder...

  • Author

That method has no implementation. Just a pair of curly braces. How should I override it, so it would show the information for the item?

 

edit1: I searched the forums for addIndormation. Apparently, it's just a matter of adding what you want to the List object. I'll try.

edit2: The only way to do the same for a block is to make a class that inherits from ItemBlock and then overriding addInformation? There must be a better way.

It is called by getToolTip(EntityPlayer, boolean) in ItemStack.

You can simply add any info as String to the given List argument, and you can format the String to put colors and such.

  • Author

Block should have one fake version of addInformation. And then Forge would find any overrides of it in our code, and create a class extending ItemBlock at runtime. Then it should "copy-paste" (or "cut-paste") our override of the fake method in Block to this automatically made ItemBlock subclass.

Block should have one fake version of addInformation. And then Forge would find any overrides of it in our code, and create a class extending ItemBlock at runtime. Then it should "copy-paste" (or "cut-paste") our override of the fake method in Block to this automatically made ItemBlock subclass.

 

Well if you believe that would be somehow easy to create and make it run efficient etc.

then by all means, create the system and do a pull request :P

 

If you guys dont get it.. then well ya.. try harder...

  • Author

Easy compared to the rest of the Forge framework, yes. So, by the standards of the autors of Forge this is probably quite easy. Easy for me? No way. By my standards making a minecart stop is a big challenge.  :-\

Easy compared to the rest of the Forge framework, yes. So, by the standards of the autors of Forge this is probably quite easy. Easy for me? No way. By my standards making a minecart stop is a big challenge.  :-\

 

A such a simple thing as a BlockBreak event is among the most requested features!

Even so it's not yet been implemented, why? Because to the standards of the forge authors there hasn't been made any suggestions on how to do this which would be efficient and good.

 

Making such system is easy, but making it work as neatly as it needs to, may be harder ;)

 

 

If you guys dont get it.. then well ya.. try harder...

Block should have one fake version of addInformation. And then Forge would find any overrides of it in our code, and create a class extending ItemBlock at runtime. Then it should "copy-paste" (or "cut-paste") our override of the fake method in Block to this automatically made ItemBlock subclass.

Why ?

You never see blocks in the inventory. They are all ItemBlock by default, which is already made automatically for all blocks that don't have a subclass of ItemBlock.

A such a simple thing as a BlockBreak event is among the most requested features!

Even so it's not yet been implemented, why? Because to the standards of the forge authors there hasn't been made any suggestions on how to do this which would be efficient and good.

or because people who really needs it use forge essential core or mine, which both does that exact features, were probably both just too lazy to actually implements it in forge

how to debug 101:http://www.minecraftforge.net/wiki/Debug_101

-hydroflame, author of the forge revolution-

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.