garbagemule / MobArena

MobArena plugin for Minecraft
GNU General Public License v3.0
189 stars 150 forks source link

Add option to reward instantly (not after the arena ends) #753

Closed VultarexCZ closed 1 year ago

VultarexCZ commented 1 year ago

This would be useful to playsound something when the wave is cleared or give supplies without supply waves.

I made my own music and I want to playsound it at the end of Wave 0 and stopsound at another wave and playsound bossmusic at another wave, but It's currently not possible, because rewards are given, when the arena ends. It would look inside config something like this:

rewards:
  waves:
    every:
      '420': <REWARD>
    after:
      '0': cmd(<NAME>):/<COMMAND>:inarena [or true, or something else..]
      '69': <REWARD>

The new part is :inarena, but it could be true or something else.

Thanks for reading and I hope this will be implemented!

prototype464 commented 1 year ago

This might be a bit of a jank solution or might not work at all but you could use https://github.com/MaksyKun/MobArenaExtension along with PlaceholderAPI and some command block magic when the wave count updates to run a playsound event.

Would be a cool implementation nonetheless!

garbagemule commented 1 year ago

From a semantics point of view, it doesn't make any sense to grant rewards instantly. Rewards are a prize you collect when the session is over.

From a "functional" point of view, the idea itself is probably much better encapsulated by #678. I'll close this issue so we can keep track of stuff in one place, but feel free to reopen if I've misunderstood something.