Ports stop sounds verb from TG #28072
Open
+24
−1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What Does This PR Do
Ports two verbs from TG:
Stop Sounds
Special verbs verb that anyone can use. Stops all sounds when used.Stop Sounds Global
Debug verb for those holding sound flags(GA+). Stops sounds for every player when used.Original PRs/commits from TG:
tgstation/tgstation#1310 (original global verb)
tgstation/tgstation@df18949 (client verb)
tgstation/tgstation#29611 (updated version)
I think I got most of the PRs but dear god this verb was subject to several non-atomic refactors. The code is all from TG with a few edits that I made for paracode/removal of blackbox logging which isn't necessary.
Why It's Good For The Game
Having the ability to stop sounds is useful for when someone does something annoying and you want the sounds to stop (like spam a dozen windup toolboxes beside you)
Admins having the ability to stop all global sound is also useful (like globally stopping sounds in the pre-game lobby so that an OGG can be played and it not interfere with the default lobby music)
Testing
Stop Sounds:
Loaded in-game
Tested the Stop Sounds while playing a sounds
Stop Sounds Global:
Started a VM client and server
Connected the VM to the server
Played a sound next to the VM client and ran the global command
Declaration
Changelog
🆑
add: Added Stop Sounds to the special verbs tab. This verb will stop all playing sound when used.
add: Added Stop Sounds Global to the debug tab. This admin only command will stop all sounds for every player.
/:cl: