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

First all, nice to be here and greetings everyone :)

 

My name is Federico, TheGoldSun on Minecraft. I'm a programmer and I recently decided to explore Forge to develop something interesting. My favourite mod is IndustrialCraft2, and actually I'm playing the experimental version, great even with bugs and unfinished mechanics. However, let me ask something to more expert modders as you are!

 

 

I wonder, how can I make an item or a block similar to buckets? I mean... Using a bucket in a recipe, the result is a new item but it returns also empty buckets. Now, of course a filled bucket (water/milk/lava ecc) has is own id, and empty bucket has another one.. So, it's there some arguments to add - may be - tu GameRegistry.addRecipe () to give player back some ItemStack? Searching in bucket classes and in Blocks and Items classes gave me no hints about it. I thought another way could be create an event handler that give player an ItemStack on the crafting of something else, but again.. no hints about that. I even thought that could be a property of item but nothing, it seems there is not anything like that in the properties or methods of Item or Block. Even possible I missed it, of course.

 

So, can anybody help me and reaveal the trick? :D

 

 

Thanks in advance, and sorry if I made some mistake explaining my question, my english is not so good.. xD

 

 

Bye!

Federico Nuzzo

Programmer and Developer

  • Author

OHHH!! Well, thanks! Tomorrow I will try. If I not misunderstood, in the istance of the item i use setContainerItem(), with - as argument - the item that have to return back after crafting? However, very thanks! I'll let you know if I solve my problem. :) Good night folks!

 

 

Edit:

 

Finally I verified the method setContainerItem and it worked perfectly, very very thanks. The starting idea is something just like the "forge hammer" or the "cable cutter" in industrialcraft, a tool usable in the crafting table that decreas his health, and I'm quite near to discover how to :D Thanks. I'll modify the topit title with [sOLVED].

Federico Nuzzo

Programmer and Developer

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.