Skip to content

SampAudioStream v2.3.1

Choose a tag to compare

@github-actions github-actions released this 22 Nov 06:23
  • Attach With Range in One Update:
    • SA_AttachAudioStreamChannelToPlayer and SA_AttachAudioStreamChannelToVehicle take an optional Float:distance. A value above 0.0 sets the hearing range together with the attachment, so listeners get one re-dispatch instead of the two caused by SA_SetAudioStreamChannelPos followed by an attach (which could make the SA-MP client play two streams at once). 0.0 keeps the current range; non-finite values are rejected.
  • Vehicle Attachments Follow World and Interior:
    • Streams and channels attached with SA_AttachAudioStreamToVehicle / SA_AttachAudioStreamChannelToVehicle now follow the vehicle's virtual world (and interior on open.mp; SA-MP 0.3.7 has no GetVehicleInterior), so a sound car moved into another world is no longer heard by players in the original world at the same coordinates. Player attachments already tracked world and interior.
  • HTTP Port List (network.http_port):
    • network.http_port is now a list of TCP ports, single ports and ascending ranges separated by commas, tried in order (default "7778-7785", e.g. "7778-7780,7785,7792"). The first free port is used immediately; when every port is busy, as happens right after a quick server restart, the list is retried every 250 ms for up to 3 s before falling back to an OS-assigned port with a warning.
    • Legacy integers keep working (7778 is a one-port list, 0 the default list); invalid lists fall back to the default.
    • A busy fixed port no longer fails initialization; it follows the same retry and fallback.
  • English System Error Messages:
    • Socket and file errors in the log are described in English (for example address already in use (10048)) instead of the localized text Windows returns.
  • Range Groups:
    • New SA_SetAudioStreamChannelGroup / SA_GetAudioStreamChannelGroup put a channel in a range group (1..31), and SA_SetPlayerAudioStreamGroupMuted / SA_IsPlayerAudioStreamGroupMuted let a player stop hearing that group through range while joined channels keep playing, so scripts can offer separate "hear boomboxes" and "hear car speakers" options instead of muting everything. The group is saved with persistent channels.
  • Titles Without File Extensions:
    • Music library tracks, folder playlist imports and direct audio file links now use the file name without its audio extension as title and queue label (Artist - Song.mp3 shows as Artist - Song), which also reaches OnAudioStreamReady, OnAudioStreamChannelTrackStart and the on-screen stream text. The library:// references keep the full file name.
  • Demo Filterscript Updated to 2.3.1 (FS_SampAudioStream_Demo.pwn):
    • Attaching a channel to your vehicle or to yourself asks for the radius and passes it in the attach call (SA_AttachAudioStreamChannelToVehicle / SA_AttachAudioStreamChannelToPlayer with distance).
    • Library track lists, the track menu and queue labels show names without the audio extension.
    • New range group demos: Channel > Spatial > Set Range Group (SA_SetAudioStreamChannelGroup / SA_GetAudioStreamChannelGroup) and main menu > Mute a Range Group (SA_SetPlayerAudioStreamGroupMuted / SA_IsPlayerAudioStreamGroupMuted).
  • No Restart When Joining or Leaving a Channel Inside Its Range:
    • Joining (SA_JoinAudioStreamChannel) or leaving (SA_LeaveAudioStreamChannel) a positioned channel while standing inside its range no longer restarts the audio: the client already plays the same stream, so the plugin only moves the player between the channel and range tiers and fires OnPlayerAudioStreamSourceChange. Typical case: getting in or out of a car whose speakers are on.