Guest User

Engine Swaps QB 1.0.3 Default Config

a guest
Dec 22nd, 2021
1,364
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 13.28 KB | None | 0 0
  1. Config = {}
  2. -- Debug mode. Should not be enabled on a live server!
  3. Config.Debug = false
  4.  
  5. -- If you're using the old QB export set this to false and enable the import in the fxmanifest.lua
  6. Config.UseNewQBExport = true
  7.  
  8. -- ghmattimysql or oxmysql
  9. Config.SqlDriver = 'oxmysql';
  10.  
  11.  
  12.  
  13. -- Key that will be used for interacting
  14. Config.InteractionKeybind = 'E'
  15.  
  16. -- true = Display values in metric (km/h, kg etc.)
  17. -- false = Display values in imperial (mph, lbs etc.)
  18. Config.UseMetric = true
  19.  
  20. -- Time in ms it takes to prepare a vehicle for engine swap
  21. Config.PrepDuration = 8000
  22.  
  23. -- Time in ms it takes to take out the engine
  24. Config.TakeOutDuration = 10000
  25.  
  26. -- Time in ms it takes to put in a new engine
  27. Config.PutInDuration = 10000
  28.  
  29. -- Time in ms it takes to drop the old engine
  30. Config.EngineDropDuration = 5000
  31.  
  32. -- Time it takes to pickup the new engine
  33. Config.EnginePickupDuration = 6000
  34.  
  35. -- Interval between syncs of all engine swapped vehicles (in ms)
  36. -- Recommended to keep it at minimum of 4000 and maximum of 20000 for big servers with performance issues
  37. Config.SyncInterval = 6000
  38.  
  39. -- Radius in which vehicles with a swapped engine will be synced
  40. -- If you experience server performance loss it is recommended to set it to a lower value
  41. -- I recommend setting this value to at least 8.0, bigger radius will result in a smoother sync
  42. Config.SyncRadius = 15.0
  43.  
  44. -- If this is set to true objects that are used during the swap won't have ownership.
  45. -- If you're having issues with the objects not syncing correctly you can turn it off
  46. Config.DontChangeObjectOwnership = false
  47.  
  48. -- Stop the engine swap if the player working on it dies or goes away from the workshop. Not stopping it might cause problems
  49. Config.StopSwapOnDeath = true
  50.  
  51. -- A stricter way of deleting objects at the workshops, think of engines and engine lifts.
  52. -- If you encounter any issues with objects being deleted unwantedly you can disable this option
  53. Config.StrictObjectDeletion = true
  54.  
  55. -- This value will slightly randomize shipment duration of all engines, shipment duration could be either faster or slower
  56. -- by this value. If you want your shipment durations to always be exactly as specified under the engine set this to 0
  57. Config.ShipmentDurationMutator = 5
  58.  
  59. -- Whether or not to enable the /hood command for opening vehicles hood
  60. Config.UseHoodCommand = true
  61.  
  62. -- When you press the laptop Backspace button twice you'll get to enjoy Snake, if you really don't like fun you can disable it
  63. Config.EnableSnakeMinigame = true
  64.  
  65.  
  66.  
  67. Config.Blacklists = {
  68.     -- Minimum amount of gears needs to have to be able to be engine swaps (electric vehicle have only 1 or 2 gears, making
  69.     -- them super overpowered with a powerful engine.
  70.     MinimumGears = 3,
  71.  
  72.     -- List of vehicle classes which should be blacklisted from getting an engine swap (https://wiki.gtanet.work/index.php?title=Vehicle_Classes)
  73.     Classes = {
  74.         8, 10, 11, 13, 14, 15, 16, 17, 18, 19, 20, 21
  75.     },
  76.  
  77.     -- List of banned vehicle models which may not be swapped
  78.     Models = {
  79.         'voltic',
  80.         'police',
  81.         'police2',
  82.         'police3',
  83.         'police4',
  84.         'sheriff',
  85.         'sheriff2',
  86.         'rcbandito',
  87.         'blazer',
  88.         'blazer2',
  89.     }
  90. }
  91.  
  92.  
  93. -- Animation that is played while preparing a vehicle for an engine swap as well during the end of a swap
  94. Config.RepairAnim = {
  95.     dict = 'mini@repair',
  96.     anim = 'fixing_a_ped',
  97. }
  98.  
  99.  
  100.  
  101. --[[
  102.     Location: location of the workshop (where vehicle is parked) (please try to keep the heading at 0, 90.0, 180.0, or 270.0)
  103.     PlayerWorkshop: Whether or not this is a player workshop (If anyone no matter their job can use it)
  104.     JobWorkshop: Job name that will be able to use the workshop
  105.     StorageName: Internal workshop name, used to save stock/storage in the database
  106.     UseSharedAccount: Whether or not it should use the balance of the job or players money when ordering an engine
  107.     SharedAccount: Name of the shared account that will be used to purchase engines
  108.     Permissions: [
  109.         SwapJobGrade: Grade of job player will need to perform a swap
  110.         PurchaseEngineJobGrade: Grade of job player will need to purchase engines
  111.     ]
  112.     Laptop: Properties of the laptop prop
  113.     Lift: [
  114.         Prop: Properties of the engine lift prop
  115.         ClearArea: If area should be cleared of any props that could be laying around
  116.         ClearRadius: Radius of the area that will be cleared
  117.         Side: Side of the vehicle where the lift will be located (Should always be on the rigth side of the car, if it's not, replace 1 with -1 or -1 with 1)
  118.     ]
  119.     EngineDropoff: [
  120.         ClearArea: If area should be cleared of any props that could be laying around
  121.         ClearRadius: Radius of the area that will be cleared
  122.     ]
  123.     NewEngine: [
  124.         ClearArea: If area should be cleared of any props that could be laying around
  125.         ClearRadius: Radius of the area that will be cleared
  126.     ]
  127.  
  128. --]]
  129. Config.Workshops = {
  130.     {
  131.         location = { x = -222.17, y = -1329.1, z = 30.9, h = 90.0},
  132.  
  133.         playerWorkshop = false,
  134.         jobWorkshop = 'mechanic',
  135.         storageName = 'mechanic',
  136.  
  137.         useSharedAccount = true,
  138.         sharedAccount = 'mechanic',
  139.  
  140.         permissions = {
  141.             swapJobGrade = 2,
  142.             purchaseEngineJobGrade = 3,
  143.         },
  144.  
  145.         laptop = {
  146.             prop = {
  147.                 x = -228.7, y = -1329.63, z = 30.85, h = 100.0, model = 'p_laptop_02_s'
  148.             }
  149.         },
  150.         lift = {
  151.             prop = {
  152.                 x = -223.87, y = -1321.5, z = 29.93, h = 90.0, model = 'prop_engine_hoist'
  153.             },
  154.             clearArea = true,
  155.             clearRadius = 10.0,
  156.             side = 1, --    1 for right side of the car, -1 for left side of the car
  157.         },
  158.         engineDropoff = {
  159.             x = -219.7, y = -1321.56, z = 30.93, h = 270.0,
  160.             clearArea = true,
  161.             clearRadius = 3.0,
  162.         },
  163.         newEngine = {
  164.             x = -220.0, y = -1333.2, z = 30.75, h = 300.0,
  165.             clearArea = true,
  166.             clearRadius = 3.0,
  167.         },
  168.     },
  169.     {
  170.         location = { x = 1091.46, y = 1326.53, z = 101.0, h = 270.0},
  171.  
  172.         playerWorkshop = true,
  173.         jobWorkshop = '',
  174.         storageName = '',
  175.  
  176.         useSharedAccount = false,
  177.         sharedAccount = '',
  178.  
  179.         permissions = {
  180.             swapJobGrade = 0,
  181.             purchaseEngineJobGrade = 0,
  182.         },
  183.  
  184.         laptop = {
  185.             prop = {
  186.                 x = 1097.1, y = 1333.42, z = 101.01, h = 270.0, model = 'p_laptop_02_s'
  187.             }
  188.         },
  189.         lift = {
  190.             prop = {
  191.                 x = 1090.96, y = 1333.17, z = 100.01, h = 10.0, model = 'prop_engine_hoist'
  192.             },
  193.             clearArea = true,
  194.             clearRadius = 3.0,
  195.             side = -1, --    change between -1 and 1 to toggle between sides of the car, dependant on workshop heading  | The lift must always be on the right side of the vehicle
  196.             rotation = 1, -- 0 for north/south, 1 for west/east
  197.         },
  198.         engineDropoff = {
  199.             x = 1088.56, y = 1334.12, z = 101.0, h = 0.0,
  200.             clearArea = true,
  201.             clearRadius = 2.0,
  202.         },
  203.         newEngine = {
  204.             x = 1095.97, y = 1323.8, z =  100.785, h = 70.0,
  205.             clearArea = true,
  206.             clearRadius = 2.0,
  207.         },
  208.     }
  209. }
  210.  
  211.  
  212. -- This will be the sound the vehicle makes after you take out the engine and still attempt to start it
  213. Config.NoEngine = {
  214.     sound = 'rcbandito'
  215. }
  216.  
  217. -- Engines will be displayed on the laptop in this order
  218. Config.AvailableEngines = {
  219.     'i4_1.6',
  220.     'i4_1.8',
  221.     'i4_2.0',
  222.     'v6_3.0',
  223.     'v6_3.6',
  224.     'v6_4.0',
  225.     'v6_6.0',
  226.     'v8_4.0',
  227.     'v8_4.3',
  228.     'v8_5.4',
  229.     'v12_5.8',
  230.     'v12_6.0',
  231. }
  232.  
  233. ---------------------------------------------------------------------------------------------
  234. -- <!> ADVANCED <!>
  235. -- If this function is enabled the function responsible for setting the vehicle handling
  236. -- will be switched from the built-in function the function located in editable.lua
  237. -- Do not change this if you do  not what you're doing
  238. Config.UseCustomHandlingSetter = false
  239. ---------------------------------------------------------------------------------------------
  240.  
  241.  
  242. -- Performance multiplier. Could be an easy way to up the performance of all (swapped)engines at the same time
  243. -- without having to configure all engines separately
  244. -- be careful while setting the maxV multiplier as it strongly influences the power in general
  245. Config.PowerMultiplier = 1
  246. Config.MaxVMultiplier = 1
  247.  
  248.  
  249.  
  250. --[[
  251.     -- Engine --
  252.     Value between the square brackets "[ ]" is the so called "key", please do not use any special symbols in the key
  253.     --
  254.     Name: Engine name
  255.     Power: Abstract power rating (acceleration)
  256.     MaxV: Abstract max speed rating (max speed, but also influences acceleration)
  257.     Mass: Weight of the engine in kg
  258.     Displacement: Size of the engine in liters
  259.     PhysicalSize: Abstract value for how big the engine is. Big engines won't fit in small vehicles
  260.     Sound: Model name of the vehicle that the sound will be used for that engine
  261.     Image: name of the image file that will be used for that engine (located in html/img/engines)
  262.     ShipmentDuration: Time in minutes it will take to receive the engine after placing an order (Mutated with the mutator)
  263.     Price: Price of the engine
  264.  
  265.     -- If you edit an existing engine all vehicles with that engine will be updated.
  266.     -- Make sure to never change or remove the engine KEY after players have purchased/equipped it.
  267.         If you really want to remove an engine from the game make sure to delete all mentions of it in the database
  268.         If you just want to make the engine unavailable for future purchase or swap remove it from the Config.AvailableEngines
  269.  
  270. ]]--
  271. Config.Engines = {
  272.     ['i4_1.6'] = {
  273.         name = 'I4 1.6L',
  274.         power = 244,
  275.         maxV = 148.0,
  276.         mass = 155.0,
  277.         displacement = 1.6,
  278.         physicalSize = 1,
  279.         sound = 'blista2',
  280.         image = 'i4_3.png',
  281.         shipmentDuration = 20,
  282.         price = 20000,
  283.     },
  284.     ['i4_1.8'] = {
  285.         name = 'I4 1.8L',
  286.         power = 190,
  287.         maxV = 148.0,
  288.         mass = 164.0,
  289.         displacement = 1.8,
  290.         physicalSize = 1,
  291.         sound = 'rebel',
  292.         image = 'i4_2.png',
  293.         shipmentDuration = 20,
  294.         price = 12000,
  295.     },
  296.     ['i4_2.0'] = {
  297.         name = 'I4 2.0L',
  298.         power = 267,
  299.         maxV = 148.0,
  300.         mass = 154.0,
  301.         displacement = 2.0,
  302.         physicalSize = 1,
  303.         sound = 'sultanrs',
  304.         image = 'i4_1.png',
  305.         shipmentDuration = 20,
  306.         price = 24000,
  307.     },
  308.     ['v6_3.0'] = {
  309.         name = 'V6 3.0L',
  310.         power = 279,
  311.         maxV = 152.0,
  312.         mass = 190.0,
  313.         displacement = 3.0,
  314.         physicalSize = 2,
  315.         sound = 'sentinel3',
  316.         image = 'v6_4.png',
  317.         shipmentDuration = 30,
  318.         price = 32000,
  319.     },
  320.     ['v6_3.6'] = {
  321.         name = 'V6 3.6L',
  322.         power = 315,
  323.         maxV = 152.0,
  324.         mass = 239.0,
  325.         displacement = 3.6,
  326.         physicalSize = 2,
  327.         sound = 'gb200',
  328.         image = 'v6_3.png',
  329.         shipmentDuration = 30,
  330.         price = 36000,
  331.     },
  332.     ['v6_4.0'] = {
  333.         name = 'V6 4.0L',
  334.         power = 324,
  335.         maxV = 155.0,
  336.         mass = 248.0,
  337.         displacement = 4.0,
  338.         physicalSize = 3,
  339.         sound = 'jester3',
  340.         image = 'v6_2.png',
  341.         shipmentDuration = 35,
  342.         price = 39000,
  343.     },
  344.     ['v6_6.0'] = {
  345.         name = 'V6 6.0L',
  346.         power = 335,
  347.         maxV = 156.0,
  348.         mass = 278.0,
  349.         displacement = 6.0,
  350.         physicalSize = 3,
  351.         sound = 'massacro',
  352.         image = 'v6_1.png',
  353.         shipmentDuration = 45,
  354.         price = 42000,
  355.     },
  356.     ['v8_4.0'] = {
  357.         name = 'V8 4.0L',
  358.         power = 332,
  359.         maxV = 161.0,
  360.         mass = 339.0,
  361.         displacement = 4.0,
  362.         physicalSize = 4,
  363.         sound = 'schlagen',
  364.         image = 'v8_3.png',
  365.         shipmentDuration = 60,
  366.         price = 44000,
  367.     },
  368.     ['v8_4.3'] = {
  369.         name = 'V8 4.3L',
  370.         power = 338,
  371.         maxV = 157.0,
  372.         mass = 344.0,
  373.         displacement = 4.3,
  374.         physicalSize = 4,
  375.         sound = 'revolter',
  376.         image = 'v8_2.png',
  377.         shipmentDuration = 70,
  378.         price = 47000,
  379.     },
  380.     ['v8_5.4'] = {
  381.         name = 'V8 5.4L',
  382.         power = 341,
  383.         maxV = 154.0,
  384.         mass = 361.0,
  385.         displacement = 5.4,
  386.         physicalSize = 5,
  387.         sound = 'tulip',
  388.         image = 'v8_1.png',
  389.         shipmentDuration = 75,
  390.         price = 47000,
  391.     },
  392.     ['v12_5.8'] = {
  393.         name = 'V12 5.8L',
  394.         power = 363,
  395.         maxV = 171.0,
  396.         mass = 323.0,
  397.         displacement = 5.8,
  398.         physicalSize = 6,
  399.         sound = 'schafter3',
  400.         image = 'v12_1.png',
  401.         shipmentDuration = 120,
  402.         price = 85000,
  403.     },
  404.     ['v12_6.0'] = {
  405.         name = 'V12 6.0L',
  406.         power = 366,
  407.         maxV = 174.0,
  408.         mass = 334.0,
  409.         displacement = 6.0,
  410.         physicalSize = 6,
  411.         sound = 'osiris',
  412.         image = 'v12_2.png',
  413.         shipmentDuration = 120,
  414.         price = 95000,
  415.     },
  416. }
Advertisement
Add Comment
Please, Sign In to add comment