Started by
MinerLevi2019
on
Topic category: Advanced modding
Hey. Newb question, but I need some help. How do you make items that explode a set amount of time after being place? And how do you make a thrown explosive?
Topic category: Advanced modding
Hey. Newb question, but I need some help. How do you make items that explode a set amount of time after being place? And how do you make a thrown explosive?
if you want to make a item like a grenade, then I would suggest making the item a ranged item that deals 0 damage, but has a prcedure linked to it where when the entity of the arrow hits a player, mob, or block(the same procedure should work for all three I think), then the coords where the arrow hit will explode.
Make a procedure to do this.
For this example I will showcase a fused bomb.
Procedure:
On player tick update:
if item in entities main hand == bomb:
bombticks = bombticks + 1
if bombticks == 100:
explode with power ? at x y z
remove 1 bomb from inventory
this would make the bomb explode after being in your hand for 5 seconds.