[Solved] How to stop sound from looping

Started by ZarephLae on

Topic category: Help with modding (Java Edition)

Last seen on 19:29, 11. Apr 2024
Joined Jun 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
[Solved] How to stop sound from looping
Tue, 03/12/2024 - 23:40 (edited)

 

Here is my procedure, it is designed to mimic the wandering trader when he goes invisible at night.

So far everything works perfectly, the only issue is related to the "Play sound" block. It seems to repeat for two seconds, basically spamming the sound until the two seconds are over then it stops. I've tried using "Break out of loop" blocks and having it not in the wait block but it still repeats itself for two seconds.

Any and all help is greatly appreciated.

 

Edited by ZarephLae on Tue, 03/12/2024 - 23:40
Last seen on 19:29, 11. Apr 2024
Joined Jun 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I tried using a local…
Tue, 03/12/2024 - 22:26

I tried using a local variable counter but it isn't working.

https://i.imgur.com/nlksCff.png

I even tried without the repeat blocks.