⚙️Configuration
Config = {
VoiceSystem = {
current = 'pma-voice',
Methods = {
['pma-voice'] = {
--- Sets the radio channel
---@param channel string
setRadioChannel = function(channel)
exports['pma-voice']:setRadioChannel(tonumber(channel))
end,
--- Gets the radio channel
---@return string
getRadioChannel = function()
return LocalPlayer.state.radioChannel
end,
--- Sets the radio volume
---@param volume number
setRadioVolume = function(volume)
exports['pma-voice']:setRadioVolume(volume)
end,
--- Sets the radio speaker state
---@param speaker boolean
setRadioSpeaker = function(speaker)
-- pma doesnt have a speaker state
end,
},
['saltychat'] = {
setRadioChannel = function(channel)
exports['saltychat']:SetRadioChannel(channel)
end,
getRadioChannel = function()
return LocalPlayer.state.radioChannel
end,
setRadioVolume = function(volume)
exports['saltychat']:SetRadioVolume(volume)
end,
setRadioSpeaker = function(speaker)
exports['saltychat']:SetRadioSpeaker(speaker)
end,
}
}
},
AppStore = {
Name = 'Radio',
Description = 'A radio app for the LB Phone',
DefaultApp = true,
},
Framework = {
useExport = true,
get = function()
return exports['es_extended']:getSharedObject()
end,
setJobEvent = 'esx:setJob',
Item = {
phoneItem = 'phone',
removeItemEvent = 'esx:onRemoveInventoryItem',
KickOutOfChannel = true,
},
Death = {
KickOutOfChannel = true,
DeathEvent = 'esx:onPlayerDeath',
DimensionCheck = {
--- Checks if the player is kickable
---@return boolean
canKickPlayer = function()
-- if return true the player will get kicked out of the radio
if exports['fd_next_gangwar']:IsInGangwar() then
return false;
end
return true;
end
}
}
},
LockedChannels = {
[1] = {
'police',
'ambulance',
}
},
Settings = {
enablePhoneNotifications = true,
clearHistoryCommand = "clearhistory",
},
Language = {
fallback = 'de',
resources = {
de = {
heading = {
title = 'Funk',
connected = 'Verbunden',
disconnected = 'Nicht verbunden'
},
favorites = {
radioId = 'Funk-ID'
},
history = {
title = 'Verlauf',
radioId = 'Funk-ID',
joined = 'Beigetreten',
left = 'Verlassen',
},
speaker = 'Lautsprecher',
input = {
radioId = 'Funk-ID',
placeholder = '12345'
},
volume = 'Lautstärke',
buttons = {
join = 'Funk beitreten',
leave = 'Funk verlassen',
},
notify = {
notAllowed = 'Du bist nicht berechtigt diese Funk zu benutzen',
joinedRadio = 'Du bist jetzt mit dem Funk %s verbunden',
leftRadio = 'Du hast den Funk %s verlassen',
}
}
},
en = {
heading = {
title = 'Radio',
connected = 'Connected',
disconnected = 'Disconnected'
},
favorites = {
radioId = 'Radio-ID'
},
history = {
title = 'History',
radioId = 'Radio-ID',
joined = 'Joined',
left = 'Left',
},
speaker = 'Speaker',
input = {
radioId = 'Radio-ID',
placeholder = '12345'
},
volume = 'Volume',
buttons = {
join = 'Join Radio',
leave = 'Leave Radio',
},
notify = {
notAllowed = 'You are not allowed to use this radio',
joinedRadio = 'You are now connected to the radio %s',
leftRadio = 'You are now disconnected from the radio %s',
}
}
}
}If you have any configuration questions or errors, feel free to open a ticket on our Discord!
Last updated