SetPlayerVoiceRange
From Onset Developer Wiki
Description
Sets the voice range of a player.
The range can't be greater than the voice distance set in the server_config.json.
To reset the voice range pass a value of 0.0 or less to this function.
Syntax
SetPlayerVoiceRange(player, range)
Parameters
- player
The player identifier. - range
The desired voice range.
Return Value
- This function returns true on success.
Example
function cmd_whisper(player)
-- Player will be heard only 5 meters (500 cm)
SetPlayerVoiceRange(player, 500.0)
end
AddCommand("whisper", cmd_whisper)