Jump to content
Search In
  • More options...
Find results that contain...
Find results in...


  • Posts

  • Joined

  • Last visited

Everything posted by Chewiie88

  1. Thanks grand_mind1! I checked BreakEvent more and found how to do it. Now my code works and i can move on to the next stage to creating this mod. Thanks alot!
  2. @grand_mind1 What im planing on doing is this. When the player digs dirt he gets x amount of xp depending on what tool he has. So what i was thinking first was to do a if statement on what tool the player using when he breaks the block. That part works. then in lets say if if(hand.getItem() == Items.wooden_shovel){ } I put an if statement on the different blocks and from there i send do the exp calculation of how mutch exp the player gets. But the problem is i dont know how i should get what type of block the player breaks. So i thought that if i check then use the ItemPickupEvent to check what item the player picked up. But i can be on the complete wrong way on coding this. There might be a easier way of doing this. Hope i explained good on what i was coding and what i have problem with.
  3. Hello. I been working on a code all day and looking up information about modding in forge. I run in to a problem and i dont know can i have 2 @SubscribeEvent methods in the same class? what im doing is a way to check if the player breaks a block and the what tool the player use. After that i want to check what item the player gets so i can set what exp he will get from it. Im working on a Adveture mod and im adding skills for mining, lumbering e.t.c Do i have to have 2 methods? Feels wrong. I want to do the check what block the player picksup in my onBlockBreak method. I feel lost at the moment any ideas? if you want to see my code just ask and i add it. No code is needed just a hint of direction so i can find out more about forge and learn more.
  4. Hello. Im new to mc modding and i run in to a problem. Cant find a function for when a player breaks a block. If im not wrong i have to lock for a break block event. If anyone know something about it im greatfull. Dont need full code for it just help to the right direction.
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.