Posted March 23, 201312 yr i have created this but the methods are out of date and i don't know how to update them. help appreciated package ashtonsmod.common; import net.minecraft.block.Block; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.world.World; public class WoodStaff extends Item { public WoodStaff(int par1) { super(par1); } public boolean onItemUse(ItemStack is, EntityPlayer player, World w, int x, int y, int z, int l, float f, float f1, float f3){ if(w.getBlockId(x, y, z) == Block.planks.blockID){ w.setBlockMetadataWithNotify(x, y, z, w.getBlockMetadata(x, y, z)+1); if(w.getBlockMetadata(x, y, z) == 4){ w.setBlockMetadata(x, y, z, 0); } else if(w.getBlockId(x, y, z) == Block.wood.blockID){ w.setBlockMetadataWithNotify(x, y, z, w.getBlockMetadata(x, y, z)+1); if(w.getBlockMetadata(x, y, z) == 4){ w.setBlockMetadata(x, y, z, 0); } }else if(w.getBlockId(x, y, z) == Block.stairsWoodSpruce.blockID){ w.setBlockWithNotify(x, y, z, Block.stairsWoodBirch.blockID); }else if(w.getBlockId(x, y, z) == Block.stairsWoodBirch.blockID){ w.setBlockWithNotify(x, y, z, Block.stairsWoodJungle.blockID); }else if(w.getBlockId(x, y, z) == Block.stairsWoodJungle.blockID){ w.setBlockWithNotify(x, y, z, Block.stairCompactPlanks.blockID); }else if(w.getBlockId(x, y, z) == Block.stairCompactPlanks.blockID){ w.setBlockWithNotify(x, y, z, Block.stairsWoodSpruce.blockID); return false; } } } } the errors are under all of the .setBlockWithNotify and the .setBlockMetadataWithNotify i know they updated these methods Use examples, i have aspergers. Examples make sense to me.
March 23, 201312 yr Author someone must have updated a mod with similar problems? Use examples, i have aspergers. Examples make sense to me.
March 23, 201312 yr they're backin 1.5.1. update to 1.5.1 or explain what the problem is, more specifcly https://minecraft.curseforge.com/members/Subaraki/projects
March 23, 201312 yr Author the firs method is undefinable and the second is unaccpetable Use examples, i have aspergers. Examples make sense to me.
March 24, 201312 yr setBlockMetadataWithNotify(x, y, z, BlockID, metaData, notify, 2) setBlockWithNotify(see above)
March 24, 201312 yr by using your brain ... T.T https://minecraft.curseforge.com/members/Subaraki/projects
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.