- The server scans the four playlist folders during autorun.
- Supported files are added to the client download list with
resource.AddSingleFile. TTTEndRoundprovides the round result.- The result is mapped to a playlist category.
- A random track is selected while avoiding an immediate repeat where possible.
- The relative path and display name are sent through
frs_play_track.
- The client receives a relative path and display name.
- The file is loaded with
sound.PlayFile. - A request identifier prevents older asynchronous callbacks from replacing newer playback.
- The persistent
frs_volumevalue is applied to the active channel. - Chat commands expose volume, track information, and stop controls.
- No networked volume setting is needed; volume is strictly local.
- Optional TTT2 globals are read defensively through
_G. - Empty playlists never call
math.randomwith an invalid range. - The server file contains server code only, and the client file contains client code only.
- No external runtime dependency is required.