Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- MOD_ FILE CONTENTS:
- package net.minecraft.src;
- import java.util.Random;
- public class mod_tutorial extends BaseMod
- {
- //Blocks
- //Items
- public static final Item RedBanana = (new ItemRedBanana(1002,10, 4, false)).setAlwaysEdible().setPotionEffect(Potion.moveSpeed.id,500,0,10).setItemName("RedBanana");
- public void load()
- {
- RedBanana.iconIndex = ModLoader.addOverride("/gui/items.png","/Items/redbanana.png");
- //Registering
- //Adding names
- ModLoader.addName(RedBanana, "Red Banana");
- //Crafting Recipes
- //Smelting Recipes
- //Shapeless Recipes
- ModLoader.addShapelessRecipe(new ItemStack(mod_tutorial.RedBanana, 1), new Object[]
- {
- mod_tutorial.Banana, Item.redstone //Crafting Line
- });
- }
- public String getVersion()
- {
- return "1.2.5";
- }
- }
- ITEM RED BANANA FILE:
- package net.minecraft.src;
- public class ItemRedBanana extends ItemFood
- {
- public ItemRedBanana(int par1,int par2, float par3, boolean par4)
- {
- super(par1,par2,par3,par4);
- }
- public boolean hasEffect(ItemStack par1ItemStack)
- {
- return true;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment