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

  • Author

Yea i didnt think getItemById was right but at the time I was willing to try anything, after reading your post I think I figured it out. I ended up creating 2 recipe types which takes care of the errors I was having in the recipe class.

 

But now Im not sure how to call the meta method in my TE, for my item method I used

ItemStack stack = AlloyRecipes.getAlloyResult(slots[0].getItem(), slots[1].getItem());

 

http://pastebin.com/3RChj41Y

 

 

  • Author

Well thanks for all your help but writing a comparison logic is just too much of a headache, when I can just create each item separately fairly easily because im using an itembase all I need to do is

in my  iteminit add

 

public static Item Ingot_Copper;

ect...

 

public static void init() {

Ingot_Copper = new itembase("ingot_copper", "item_ingot_copper");

ect...

}

 

 

its really no harder than creating an enum class and makes the custom recipe work without any headache

 

And Thanks Again

 

  • Author

Because it lets me use

 

 

private static ItemStack getOutput(Item item, Item item1) {

 

if (item == ModItems.Ingot_Copper && item1 == ModItems.Ingot_Tin

|| item == ModItems.Ingot_Tin && item1 == ModItems.Ingot_Copper) {

return new ItemStack(ModItems.Ingot_Bronze, 2);

}

return null;

 

}

 

which works fine

  • Author

I know but due to the hassle of using meta vs the ease of separate items Iv decided to use separate items.

So even though Im not using meta anymore our discussion has shown that you can use meta by writing your own comparison logic or you can separate items.

So now ppl who look at this post can see the 2 methods that can be used and decide for themselves how they want to do custom recipes.

Now should I edit the OP to state this? 

  • Author

Thats why its up to modders to decide how best to use each method. For me due to the fact Im only creating a small handful of ingots and the ease of creating separate items Im using that method for this case. However for other items that use standard recipes Ill be using meta.

 

And besides just think of how big of a mod you would need to make to even come close to hitting the ID max I mean there are mods out there that have hundreds of items and mod packs that have countless mods in them and yet theres been no prob with IDs.

And besides just think of how big of a mod you would need to make to even come close to hitting the ID max...

 

You mean about 32,000?

Feed The Beast runs up against that limit all the time.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

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.