How do i make a procedure "When the item/tool break" ?

Started by Sitonic on

Topic category: Help with MCreator software

Joined Dec 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How do i make a procedure "When the item/tool break" ?

Obs: I'm Brazilian and I don't speak English very well, sorry.

 

In the "Triggers" tab for items, tools and armor, there is no "when to break" procedure. How do I procedure this manually?

Joined Feb 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Hey, I'm Brazilian too :)!…
Thu, 02/25/2021 - 14:36

Hey, I'm Brazilian too :)!
Well, you can do the following:
1- Use the trigger when the tool is in hand
2- In item procedures, there is the following method: take the item's durability (or something)
3- Using the If block, check if the durability is 0
4- Then put what you want to do.

If it doesn't work you can use a loop:
1- While the tool is in the main hand = "tool name", if the item’s durability is = 0, do something 

Joined Dec 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
 I will test, thanks.
Fri, 02/26/2021 - 03:56

 I will test, thanks.

Joined Feb 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Did this work? :D  
Sat, 05/28/2022 - 22:31

Did this work? :D