1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Sign up for news, events and more!

    You're currently visiting the official DarkRP Forums as a guest. Sign up now to participate in our community and we'll let you know when we have news.

Release Police Radio

Discussion in 'DarkRP Addon & Plugin Releases' started by LordiAnders, Mar 12, 2014.

  1. Feldma

    Feldma Member

    That uh, doesn't seem to do anything with the Police Radio...?
  2. joe.aldred

    joe.aldred New Member

    If a player is gagged in ULX, they can still use the radio. Where would I put the 'ply:GetNWBool("ulx_gagged", false)' in the code to stop them from transmitting their voice if gagged? Thanks, this is a brilliant addon!
  3. LordiAnders

    LordiAnders Active Member

    Add it after ply1:getDarkRPVar("Police_Radio_Enabled") in sv_p_radio.lua at line 17

    EDIT: Oops. You should probably make a NEW line after 17. Hopefully you'll figure it out.
  4. joe.aldred

    joe.aldred New Member

    Thanks for your instant reply!
  5. Ok, this is cool and all, but as soon as I put this file into my server and restarted shit hit the fan.
  6. LordiAnders

    LordiAnders Active Member

    Can't you be a bit more specific? Any errors?
  7. darknight74

    darknight74 New Member

    Somebody can help me, because I don't know where I must place the file.
    Thank you for your help,
    Cordially darknight74
  8. Shockwraithx

    Shockwraithx New Member

    fucking shit still having problems with the icons i made its own autorun/server file and i saw my client download it, but i went in game and still purple and black textures. I did all the steps put the materials in the server's materials folder and it went directly into vgui/lordi/darkrp and still purple and black
  9. LordiAnders

    LordiAnders Active Member

    You can disable the icon if you don't want to bother with it.
  10. Shockwraithx

    Shockwraithx New Member

    i kinda want to, But i really want the icons they look clean and nice i made its own forcedl file too
    But its still missing textures ingame..
    Any other tips?
    --- Double Post Merged, May 14, 2016 ---
    oh im so retarded i checked my config file and the radio in the config is police while the icons title is polis
    --- Double Post Merged, May 14, 2016 ---
    still didnt work D:
    Last edited: May 14, 2016
  11. White Barack Obama

    White Barack Obama New Member

    If i wanted to put this on my MilitaryRP server where would i put it and what would i do to restrict it to jobs of SGT CPT GEN etc?
  12. cj2tech

    cj2tech Member

    You would need to put in the addon folder. And out all the materials and such in your fastdl
  13. White Barack Obama

    White Barack Obama New Member

    How i restrict it to certin jobs?
  14. VANBAN

    VANBAN New Member

    hey is there a way so i can have it so that saythe mob boss has a seperate radio then the police?
    --- Double Post Merged, Aug 21, 2016 ---
    how do i set it up so i can have a mob boss radio as well as a police radio?
    Last edited: Aug 21, 2016
  15. WolvesRoot

    WolvesRoot New Member

    Can you help? I can't get the file working. I place it into dark_module nothing happend, moved it into addons, nothing happend HELP
  16. FletcherTime

    FletcherTime Member

    Is there a way I can change the assigned keys to activate and deactivate the radio. It is conflicting with another addon I have.
  17. Pab14567

    Pab14567 Well-Known Member

    the config file
  18. FletcherTime

    FletcherTime Member

    Code (Text):

    Police_Radio_Allow_Teams = {"cp","chief","mayor","swat","detect", "bhunter"} --The script will normally use the jobs set by GAMEMODE.CivilProtection. If it doesnt work add the remaining team here
    --^^ These are CHAT COMMANDS!! Not teamnames

    Police_Radio_Require_Admin_Approval = false --Whether or not its required for admins to approve users first before they can use their radio

    Police_Radio_Only_If_On = false --Only transmit voice if the receiving player has their own radio on

    if CLIENT then
    Police_Radio_HUD_Text_On = "Radio is on - All Police can hear your voicechat!" --The text that appears above the radio icon if enabled (Set to "" to disable text)
    Police_Radio_HUD_Text_Off = "Radio is off (%s + %s to enable it)" --If the radio is disabled this text will appear (choose "" to disable text)
    Police_Radio_HUD_Vehicle_Text_Off = "Radio is off (%s to enable it)" --If the radio is disabled and the player is in a vehicle this text will appear (choose "" to disable text)
    --%s will be replaced with the key bound by the player that needs to be pressed

    Police_Radio_HUD_Enable = true --Set to true to enable the HUD icons
    Police_Radio_HUD_Use_Textures = false --If enabled. The HUD will use texture files (vtf) instead of a png file
    Police_Radio_HUD_Texture_On = "vgui/lordi/darkrp/police_radio_on" --If you want to... You can set your own custom texture for the radio icon
    Police_Radio_HUD_Texture_Off = "vgui/lordi/darkrp/police_radio_off" --Texture that appears if the radio is currently off
    --******* ^^ These settings will affect your download! *******

    --When selecting a texture, MAKE SURE THE EXTENSION ISNT INCLUDED (.png/.vmt)
    --The script does this by itself
    Would I change the "Police_Radio_HUD_Text_Off" string? Wouldn't that just change the the text and not the actual keypress?
  19. Pab14567

    Pab14567 Well-Known Member

    waaaat. @LordiAnders you didn't a option to change key of which is can be turned off and on ? I thought you did

    @FletcherTime just try to see if you can change the opening key for the other addon
  20. LordiAnders

    LordiAnders Active Member

    I suppose I'll have a look at implementing it later today, seeing as it's been one of the most requested features.
    It will probably function identically to surrender's shout key, so server owners won't enforce it on a key people keep binds on.

    EDIT: Also, sorry about the late response! I forgot to view the forum while logged in, so I didn't receive any e-mails about people posting here.
    --- Double Post Merged, Oct 15, 2016 ---
    Took a little longer than expected, thanks to me forgetting... Oh well.
    • Fixed an issue where the F1 help menu entries didn't turn green, because I forgot to change the variable to the new format.
    • Changed the order for job detection (Previously: jobtable or isCP, is now: isCP or jobtable, not really important though)
    • Replaced a few ! with . in the chat messages for the /giveradio and /removeradio commands.
    • Changed SetPData("Police_Radio_Allow",false) to RemovePData("Police_Radio_Allow") to clear the data entirely.
    • SendLua has been changed to networked messaging instead.
    • Replaced a few LocalPlayer function calls with a cached variable instead.
    • Removed the "automatic download" functionality, as it didn't even seem to work. You need to add the textures to download manually.
    • Players can now customize their key to toggle between the radio's states. This replaces ALT+E with T, and can be changed in Q > Options > Police Radio > Keybindings
    • The HUD_Vehicle_Text_Off variable is no longer used, as it's no longer neccesary now that the key can be changed to something that doesn't interfere with vehicle functionality.
    The way the addon is to be installed has also changed. It's to be installed in the addons folder now, instead of darkrpmodification.
    Last edited: Oct 15, 2016

Share This Page