Advertisement
TheDenVxUA

Untitled

Aug 5th, 2019
168
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 3.63 KB | None | 0 0
  1. AGC = AGC or {}
  2. --[[---------------------------------------------------------------------------
  3. Advanced Government Computer : Config
  4. INFO: ACCESS TO COMPUTER
  5. Commands :
  6. agc_resetalllogs - explicit
  7. agc_save - explicit on agc's entities
  8. agc_remove - same as above
  9. ---------------------------------------------------------------------------]]
  10. AGC.Version = "2.2.0"
  11. -- NPC Model
  12. AGC.NPC_Model = "models/icpd/cops/male_02_longsleeved.mdl"
  13. --Cooldown before an other complaint
  14. AGC.Complaint_Cooldown = 60 * 5 -- 5 minutes
  15. -- Vehicles models that have access to AGC, don't forget to remove the comma at the last line
  16. -- Add vehicles models here
  17. AGC.VehicleAccess = {
  18.     "models/lonewolfie/dodge_charger_2015_police.mdl",
  19.     "models/lonewolfie/chev_impala_09_police.mdl",
  20.     "models/lonewolfie/chev_suburban_pol.mdl",
  21.     "models/lonewolfie/chev_suburban_pol_und.mdl",
  22.     "models/tdmcars/gtav/police.mdl",
  23.     "models/tdmcars/gtav/police3.mdl",
  24.     "models/tdmcars/gtav/riot.mdl",
  25.     "models/tdmcars/hsvw427_pol.mdl",
  26.     "models/tdmcars/emergency/dod_charger12.mdl",
  27.     "models/tdmcars/emergency/for_crownvic.mdl",
  28.     "models/buggy.mdl",
  29.     "models/tdmcars/emergency/mitsu_evox.mdl"
  30. }
  31. -- Who can delete a complaint, don't forget to remove the comma at the last line
  32. AGC.DeleteComplaint = {
  33.     "Civil Protection Chief",
  34.     "Диспетчер 911",
  35.     "Мэр"
  36. }
  37. --[[---------------------------------------------------------------------------
  38. Hacking module : config
  39. ---------------------------------------------------------------------------]]
  40. -- Hacking module enabled ?
  41. AGC.Hack_Enabled = true
  42. -- Hacker job
  43. AGC.Hacker_Job = false
  44. -- Hacker job name
  45. AGC.Hacker_Jobname = {
  46.     "Hacker",
  47.     "Citizen"
  48. }
  49. -- Hacking time
  50. AGC.Hack_time = 5
  51. -- Time between 2 fail hack
  52. AGC.Hack_Cooldown = 1
  53. --[[---------------------------------------------------------------------------
  54. DarkRP Commands config
  55. ---------------------------------------------------------------------------]]
  56. -- The police will use the computer to wanted/warrant/unwanted.. someone. (No commands)
  57. -- Set false if you want disabled default warrant/wanted/ect.. and force cops to use computer
  58. AGC.Default_Warrant = false
  59. AGC.Default_Wanted = false
  60. --[[-------------------------------------------------------------------------
  61. NEW 2.2
  62. ---------------------------------------------------------------------------]]
  63. AGC.ComplaintsExpiration = 0
  64. AGC.MainLanguage = "Russian" -- Edit below >> or set to English or French
  65. AGC.DeleteLogsOnDisconnect = false
  66. AGC.DeleteLogsOnDeath = false
  67. -- insert your driver license check function, here it's compatible with TooBad's script (first license)
  68. AGC.DriverLicenseEnabled = true
  69. AGC.DriverLicenseFunction = function(ply) return ply:HasDLicense(2) end
  70. AGC.DeleteLogs = {
  71.     "Civil Protection Chief",
  72.     "Глава Полиции",
  73.     "Диспетчер 911",
  74.     "Мэр"
  75. }
  76. --[[---------------------------------------------------------------------------
  77. End of config
  78. ---------------------------------------------------------------------------]]
  79. function isNearAHackedComputer(ply)
  80.     if not IsValid(ply) or not ply:Alive() or not AGC.Hack_Enabled or (AGC.Hacker_Job and not table.HasValue(AGC.Hacker_Jobname, team.GetName(ply:Team()))) then return false end
  81.     for k,v in pairs(ents.FindInSphere(ply:GetPos(), 64)) do
  82.         if IsValid(v) and v:GetClass() == "apc_computer" and v:GetAGCHacked() then return true end
  83.     end
  84.     return false
  85. end
  86.  
  87. local function loadAGCModules()
  88.     if DarkRP and (not AGC.Default_Warrant or not AGC.Default_Wanted) and SERVER then
  89.         include("autorun/modules/sv_agc_darkrp.lua")
  90.     end
  91. end
  92. loadAGCModules()
  93. hook.Add("DarkRPFinishedLoading", "AGC_Modules", loadAGCModules)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement