Code Studio
Tebex DiscordYoutubeGitHub
  • 🌟Welcome to Code Studio
  • Overview
    • 💡What we do
  • 📜Our Scripts
    • Ultimate License System
      • 🛠️Setup
    • Bodycam & Dashcam
      • 🛠️Setup
    • Weather Management
      • 🛠️Setup
    • Car Radio - Car Play Pro
      • 🛠️Setup
    • Modern HUD
      • 🛠️Setup
    • Modern Shops
      • 🛠️Setup
    • Advanced Radio
      • 🛠️Setup
    • Modern ID Card
      • 🛠️Setup
    • Billing Invoice System
      • 🛠️Setup
    • Radial Menu
      • 🛠️Setup
    • Death Screen
      • 🛠️Setup
    • Boss & Gang Menu
      • 🛠️Setup
    • Advanced Notification
      • 🛠️Setup
    • Fingerprint Scanner
      • 🛠️Setup
    • Drunk System + Alcohol Tester
      • 🛠️Setup
    • Advanced Job + ID Card
      • 🛠️Setup
    • Drug Selling + Level Based
      • 🛠️Setup
    • Multi Job System
      • 🛠️Setup
    • Discord2FiveM [V2]
      • 🛠️Setup
    • Modern Radio
      • 🛠️Setup
    • Grappling Gun
      • ♦️Standalone
  • ⚠️FiveM Escrow Protection FAQ
    • Home
    • Error parsing script ... <\1>
    • Failed to verify protected resource
    • You lack the required entitlement
    • What to do if nothing is fixing the errors
Powered by GitBook
On this page
  • Detailed Config is provided with the script with detailed information:
  • Events
  • Exports
  • Usages
  • Additional detailed guidance can be found in the config itself. If you need further assistance, please feel free to contact us on Discord.
  1. Our Scripts
  2. Advanced Radio

Setup

This is a detailed setup guide for Advanced Radio. If you have any questions before making a purchase, you can contact us on Discord

PreviousAdvanced RadioNextModern ID Card

Last updated 2 months ago

Detailed Config is provided with the script with detailed information:

Supports Every Server: QBCore, ESX, Standalone

Events

  • Open Radio UI
    TriggerEvent('cs:advradio:openRadio', 1) --To Use Model 2 put 2 insted of 1
  • Close Radio UI
    TriggerEvent('cs:advradio:closeUI')
  • Open Radio Scanner UI
    TriggerEvent('cs:advradio:openScanner')
  • Remove Player From Radio
    TriggerServerEvent('cs:advradio:forceLeave', 1) -- You can provide a player ID to remove a specific player from radio
  • Set Dead Status [true,false]
    TriggerEvent('cs:advradio:isDead', true) --true/false Update Death Status from youreath script
  • Emergency Alert
    TriggerServerEvent('cs:advradio:alertAll', channel) -- alert in specific channel

Exports

  • Check Current Channel
    exports["cs_walkietalkie"]:isInRadio() --Fetched Player's Channel
  • Join Radio By Export
    -- This export can be used on both the server and client sides --
    
    -- return: 'connected', 'restrict', 'password'
    exports["cs_walkietalkie"]:joinRadio(channel)  --Client
    
    -- return: 'connected', 'restrict', 'password'
    exports["cs_walkietalkie"]:joinRadio(playerID, channel)  --Server

Usages

You can customize this script to support every voice system: pma-voice, toko-voip, saltychat

*It supports Mumble VOIP as well, but since pma-voice is the latest version of Mumble, we recommend using that. However, if you still prefer Mumble, you can continue using this script, and it will work with Mumble as well

RegisterNetEvent('cs:advradio:connect', function (channel, connect)
    if connect then
        -- PMA Voice --
        exports["pma-voice"]:setRadioChannel(channel)
        exports["pma-voice"]:setVoiceProperty("radioEnabled", true)

        -- Toko Voip --
        -- exports.tokovoip_script:addPlayerToRadio(channel)
        -- exports.tokovoip_script:setPlayerData(GetPlayerName(PlayerId()), "radio:channel", channel, true)

        -- Salty Chat --
        -- exports.saltychat:SetRadioChannel(tostring(channel), true)
    else
        -- PMA Voice --
        exports["pma-voice"]:setRadioChannel(0)
        exports["pma-voice"]:setVoiceProperty("radioEnabled", false)

        -- Toko Voip --
        -- exports.tokovoip_script:removePlayerFromRadio(exports.tokovoip_script:getPlayerData(GetPlayerName(PlayerId()), "radio:channel"))
        -- exports.tokovoip_script:setPlayerData(GetPlayerName(PlayerId()), "radio:channel", "nil", true)

        -- Salty Chat --
        -- exports.saltychat:SetRadioChannel("", true)
    end
end)

RegisterNUICallback('setVolume', function(curVol, cb)
    -- PMA Voice --
    exports['pma-voice']:setRadioVolume(tonumber(curVol))

    -- Toko Voip --
    -- exports.tokovoip_script:setRadioVolume(tonumber(curVol))

    -- Salty Chat --
    -- exports.saltychat:SetRadioVolume(tonumber(curVol))
end)

Additional detailed guidance can be found in the config itself. If you need further assistance, please feel free to contact us on Discord.

📜
🛠️