Advertisement
szymski

Untitled

Mar 6th, 2016
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.81 KB | None | 0 0
  1. /*----------------------------
  2. Global table
  3. ------------------------------*/
  4.  
  5. UBR = { };
  6. UBR.Config = { };
  7. UBR.Networking = { }; // Contains networking functions
  8.  
  9. /*----------------------------
  10. Settings
  11. ------------------------------*/
  12.  
  13. UBR.Config.AdminGroups = { "superadmin", "admin", "owner" };
  14.  
  15. UBR.Config.AlarmActivationRange = 1000;
  16. UBR.Config.AlarmHealth = 100;
  17. UBR.Config.AlarmRepairDelay = 30;
  18. UBR.Config.AlarmRingTime = 20;
  19. UBR.Config.AlarmRepairTime = 3;
  20.  
  21. UBR.Config.C4ExplodeDelay = 10;
  22. UBR.Config.C4DestroyDoors = true;
  23. UBR.Config.C4DoorRespawnDelay = 20;
  24. UBR.Config.C4DoorRepairTime = 8;
  25.  
  26. UBR.Config.LockpickTime = 20;
  27.  
  28. UBR.Config.SafeMoney = 10000;
  29. UBR.Config.SafePlunderTime = 2;
  30. UBR.Config.SafeRefillDelay = 300;
  31. UBR.Config.SafeSilverValue = 2000;
  32. UBR.Config.SafeGoldValue = 4000;
  33. UBR.Config.SafeDiamondValue = 8000;
  34.  
  35. UBR.Config.VaultDoorHealth = 5000;
  36. UBR.Config.VaultDoorRepairTime = 15;
  37.  
  38. UBR.Config.DrillRepairTime = 2;
  39.  
  40. UBR.Config.ShopItems = {
  41. {
  42. Name = "Lockpick",
  43. Description = "Useful for silent robbery.",
  44. Price = 3000,
  45. Model = "models/weapons/w_crowbar.mdl",
  46. BuyFunc = function(ply) {
  47. ply:Give("swep_lockpick");
  48. }
  49. },
  50. {
  51. Name = "C4",
  52. Description = "Great for loud and fast raids. Placed on a door or safe instanly breaks it.",
  53. Price = 8000,
  54. Model = "models/weapons/w_c4.mdl",
  55. BuyFunc = function(ply) {
  56. ply:Give("swep_ubr_c4");
  57. ply:GiveAmmo(1, "ubr_c4_ammo", false);
  58. }
  59. },
  60. {
  61. Name = "Basic Drill",
  62. Description = "Without a drill, you won't be able open the vault door. Don't forget to buy it!",
  63. Price = 2000,
  64. Model = "models/weapons/w_smg_tmp.mdl",
  65. BuyFunc = function(ply) {
  66. ply:ChatPrint("Not implemented!");
  67. }
  68. },
  69. {
  70. Name = "Reinforced Drill",
  71. Description = "Faster than basic drill.",
  72. Price = 5000,
  73. Model = "models/weapons/w_smg_tmp.mdl",
  74. BuyFunc = function(ply) {
  75. ply:ChatPrint("Not implemented!");
  76. }
  77. },
  78. {
  79. Name = "Diamond Drill",
  80. Description = "Super fast drill. The best choice for exprienced robbers.",
  81. Price = 15000,
  82. Model = "models/weapons/w_smg_tmp.mdl",
  83. BuyFunc = function(ply) {
  84. ply:ChatPrint("Not implemented!");
  85. }
  86. },
  87. {
  88. Name = "Durable Crate",
  89. Description = "You'll need this, if you want to steal something more than just money. After a successful robbery, bring this to me, I'll pay you.",
  90. Price = 100,
  91. Model = "models/props_junk/PlasticCrate01a.mdl",
  92. BuyFunc = function(ply) {
  93. var crate = ents.Create("ubr_crate");
  94. crate:SetPos(ply:GetPos() + Vector(0, 0, 90));
  95. crate:Spawn();
  96. crate:PhysWake();
  97. }
  98. },
  99. };
  100.  
  101. UBR.Config.Lang = { };
  102.  
  103. UBR.Config.Lang.NPC = "Gangster boss";
  104.  
  105. UBR.Config.Lang.C4WeaponName = "C4";
  106.  
  107. UBR.Config.Lang.RepairingAlarm = "Repairing alarm";
  108. UBR.Config.Lang.RepairingDoor = "Repairing door";
  109. UBR.Config.Lang.RepairingVaultDoor = "Repairing vault door";
  110. UBR.Config.Lang.RepairingDrill = "Repairing drill";
  111. UBR.Config.Lang.Lockpicking = "Lockpicking";
  112. UBR.Config.Lang.Plundering = "Plundering";
  113.  
  114. UBR.Config.Lang.ShopTitle = "Ultimate Bank Robbery Shop";
  115. UBR.Config.Lang.ShopBuy = "Buy";
  116. UBR.Config.Lang.ShopClose = "Close";
  117.  
  118. UBR.Config.Lang.ToolDescription = table.concat({
  119. "This tool saves Ultimate Bank Robbery entities and custom props (you can build a custom vault).",
  120. "You don't need to add Ultimate Bank Robbery entities, those are saved automatically.",
  121. "",
  122. "Left mouse button: Add/removes a custom prop.",
  123. "Right mouse button: Saves .",
  124. }, "\n");
  125. UBR.Config.Lang.ToolUBREntityClick = "You don't need to mark addon's entities. Those are saved automatically.";
  126.  
  127.  
  128. /*----------------------------
  129. Includes
  130. ------------------------------*/
  131.  
  132. include("util.lua");
  133. include("npc_controller.lua");
  134.  
  135. if (SERVER)
  136. {
  137. include("networking_server.lua");
  138. include("saving_loading.lua");
  139. }
  140.  
  141. if (CLIENT)
  142. {
  143. include("networking_client.lua");
  144. }
  145.  
  146. /*----------------------------
  147. Ammo types for weapons
  148. ------------------------------*/
  149.  
  150. game.AddAmmoType({
  151. name = "ubr_c4_ammo"
  152. });
  153.  
  154. if(CLIENT)
  155. language.Add("ubr_c4_ammo_ammo", UBR.Config.Lang.C4WeaponName);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement