How to make a right click procedure only work again when the procedure is done?

Started by Capuch on

Topic category: Help with MCreator software

Active 3 years ago
Joined Nov 2021
Points:
530

User statistics:

  • Modifications: 0
  • Forum topics: 5
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 2
How to make a right click procedure only work again when the procedure is done?
Sun, 11/21/2021 - 00:21 (edited)

The title probably sounds, but I made an item that plays a certain song that's 3 minutes long when an item is right clicked, and when I spam click it, the song overlaps, so how can I make it so that it only plays the sound again after it's done playing the sound orignially?

Edited by Capuch on Sun, 11/21/2021 - 00:21
Active 1 year ago
Joined Oct 2020
Points:
1616

User statistics:

  • Modifications: 0
  • Forum topics: 15
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 1874
wait blocks or nbt tags…
Sun, 11/21/2021 - 01:55

wait blocks or nbt tags depending if it's a block, if not global variables 

Active 4 months ago
Joined Dec 2021
Points:
585

User statistics:

  • Modifications: 1
  • Forum topics: 10
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 66
Hi, you could do that like…
Sun, 12/12/2021 - 14:59

Hi, you could do that like this:

Im sorry if the image doesn't work, but here it is: https://sta.sh/0g2e54bt0aj

Just name the NBT tag with any name and replace "Custom code snippet: UR ACTION" with whatever actions should be executed each time it is triggered, then attach it into a right-click trigger, it requires only the entity dependency.

You're welcome.

Active 4 months ago
Joined Dec 2021
Points:
585

User statistics:

  • Modifications: 1
  • Forum topics: 10
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 66
Should*
Sun, 12/12/2021 - 15:03

Should*