This repository has been archived on 2025-12-11. You can view files and clone it, but cannot push or open issues or pull requests.

22 lines
516 B
Markdown
Raw Normal View History

2025-02-02 10:40:42 +01:00
## addChannelCheck
## Description
Adds a channel check to radio channels.
## Parameters
* **channel**: The channel to add the check to.
* **function**: the function to call when the check is triggered, which should return a boolean of if the player is allowed to join the channel..
```lua
-- Example for addChannelCheck
-- this always has to return true/false
exports['pma-voice']:addChannelCheck(1, function(source)
if IsPlayerAceAllowed(source, 'radio.police') then
return true
end
return false
end)
```