Aspiring-Mod-Maker Posted June 15, 2014 Posted June 15, 2014 I saw this somewhere once before, but I guess I did not bookmark it with all the rest of my tutorial links. Oops. I am adding a battery-like item to my mod, as a crafting material to make more complex items. I would also like to include extra recipes that support a few battery-like items from other mods to be useable as a replacement for my battery. I know the basic concept of how I have to check if the other mod is present to check if the recipe needs to be active or not, but I do not remember any of the specific methods/functions to use in my code. Also, by chance, does anyone know the coded item names of IC2's RE Battery and/or Galacticraft 2's Battery? These are the items I want to add recipe support for in case you couldn't guess. Quote
jabelar Posted June 15, 2014 Posted June 15, 2014 One trick is you can just make a debug method in your mod that lists names and/or ids of all the registered items (or blocks or entities) to the console, and then run your mod with the other mods. I think you can probably also inspect the lang files of the other mods. Quote Check out my tutorials here: http://jabelarminecraft.blogspot.com/
Roflcopter Posted June 16, 2014 Posted June 16, 2014 Use the Ic2 Api http://ic2api.player.to:8080/job/IC2_experimental/397/ battery name // batteries reBattery; // Empty RE Battery item, currently not meta sensitive chargedReBattery; // RE Battery item, meta = damage value for charge level advBattery; // Adv Batteryitem, meta = damage value for charge level energyCrystal; // Energy Crystal item, meta = damage value for charge level lapotronCrystal; // Lapotron Crystal item, meta = damage value for charge level suBattery; // SU Battery item, meta = damage value for charge level Quote
Mitchellbrine Posted June 16, 2014 Posted June 16, 2014 CraftingManager.getInstance().getRecipeList().add(new ShapelessOreRecipe(new ItemStack(/*Crafting Result*/, 1), "XY",'X',"battery",'Y',/*Other Item*/)); That's assuming they both register in the ore dictionary as "battery" Quote -Mitchellbrine Minecraft can do ANYTHING, it's coded in Java and you got the full power of Java behind you when you code. So nothing is impossible. It may be freaking fucking hard though, but still possible If you create a topic on Modder Support, live by this motto: I don't want your charity, I want your information
Recommended Posts
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.