[Paid][ESX] Mechanic Job


Hello again!

Today I bring you my alternative to the good old fashioned, overused, esx_mechanicjob which a lot of servers still use. A lot of esx_mechanicjobs functionality is not even used by most servers, merely just providing a job for the player and menu and that’s about it. So upon request I decided to try and tackle that, cut the waste, and provide something more for players to do.

As usual for my scripts, I incorporated PolyZone & bt-target into them, specifically the towing job. This allows me to keep the resource usage very low, and should be steady at or around 0.01 ms.

So whats in the script?

  • Repair/Patch Kits - Both of these have been improved upon over the normal mech repair, adding an animation, timer, requirement to be at the front of the car, as well as visual improvements like the hood automatically opening, a toolbox prop being spawned when working on the car.
    Repair kits will fully heal the engine health of a car
    Patch Kits will heal only a certain amount of engine health (150 in the script, can be changed in client.lua)
    Neither of which will repair the body damage, making using Bennys/Los Santos Customs more valuable.

  • A menu triggered via NPC Interaction, includes renting a tow truck, starting a tow job, and accessing the boss menu (only the boss can access the boss menu, obviously). This uses the standard esx_society boss menu, for ease of use since a lot of people are accustomed to it.

  • A Tow Job! esx_mechanicjob has one as well but is pretty buggy, and I’m not sure if its OneSync compatible, however this one is. It incorporates bt-target & PolyZone to create EntityZones on your tow truck & car to access them via the Alt-Menu (or third eye as people like to call it)

  • The Job has 21* locations set up by default, including a wide variety of cars that may be spawned to tow, and is VERY EASY to edit in the config to add new locations, or vehicles.

  • The ability to tow players cars, via a /tow command and then taking them to the impound lot to poof them.

  • A very easy to edit config file, fully commented code, and a big smile.

  • THERE IS NO F6 Menu, instead Mechanics will repair using the actual items (fixkit and fixtool, are their respective names in the database). BUT! When Mechanics use them, THEY WILL NOT BE REMOVED. Only when NON-Mechanics use them.

  • Allowing Mechanics the ability to craft Repair/Patch kits via the Alt-Menu inside the mech shop. Requires any materials you’d like it to, can edit the item and amount via the Config.

  • ONLY Mechanics can access the Mechanic-NPC inside the shop, and the crafting menu.
    When no one is around the ped, he will despawn and only respawn when someone is within distance, to help keep ped count low so no pool crashes.

Video Preview
Config Picture
Config Picture 2

Dependencies:
ESX
mythic_notifications (for notifications, easy to change if you don’t want to use it)
PolyZone - REQUIRED
bt-target - REQUIRED
progressBars - Can change out for your own progressBars or remove entirely (Will require you to remove it from client.lua)

Get it here from Tebex

ATTENTION!!! IF you buy the script, you’ll have to make a quick edit to bt-target > client.lua. By default, bt-target did not incorporate PolyZone’s EntityZone so I added it in myself.
You’ll have to add the following code:

function AddEntityZone(name, entity, options, targetoptions)
Zones[name] = EntityZone:Create(entity, options)
Zones[name].targetoptions = targetoptions
end

exports(“AddEntityZone”, AddEntityZone)

Place it with the other functions inside bt-target > client.lua
YOU ALSO Need to add the following items to your database unless you change them;
rubber, scrapmetal, fixtool, fixkit

Thanks for checking it out, even if you don’t buy. Any comments or suggestions are widely appreciated.

Some of my other scripts:
Jewelry Store Robbery
Humane Labs Heist(Save the chimps!)
More Interactive Stores

13 Likes

sold!

2 Likes

Forgot to mention, if you previously used esx_mechanicjob, you won’t have to do anything else as the items are already added in. There is no SQL provided with the script, so if you plan on using it out the box you’ll have to manually go into your database and add the following items
scrapmetal
rubber

if you didn’t use esx_mechanicjob then you need to also include
fixtool
fixkit

1 Like

Very awesome can’t wait to check it out!

1 Like

Does this also do what lscustoms does so you can upgrade peoples car and charge them?

No sir, this does not include ls customs or bennies or anything, their are two awesome tuning scripts that were released I think yesterday though, if thats what you need check them out!

Quick update! It seems bt-target doesn’t get the jobs right so please make the following changes and it will work for you!
Replace bt-target client.lua LINE 12 to LINE 28 WITH THE FOLLOWING BELOW

local PlayerJob = nil
local PlayerData = {}
Citizen.CreateThread(function()
while true do
Wait(5000)
if ESX ~= nil then
PlayerData = ESX.GetPlayerData()
if PlayerData.job ~= nil then
PlayerJob = PlayerData.job.name
end
else
TriggerEvent(‘esx:getSharedObject’, function(obj) ESX = obj end)
end
RegisterNetEvent(‘esx:setJob’)
AddEventHandler(‘esx:setJob’, function(job)
PlayerJob = job
end)
end
end)

THEN REPLACE Line 47 and Line 83 WITH THIS LINE

if v == “all” or v == PlayerJob then

on both 47 and 83 replace that line

So this script is basically towing job with posibility to repair the car? (No tuning as normal in mechanic job)

Correct, however there is more to come so if you’re not convinced yet then I recommend waiting and checking it out later.

I like it don’t get me wrong, but I would like to see something so it’s more like towing company or I don’t know. (basically some improvements/upgrades)

Works Great. Even helped me for a while adding some extra things to it to fit my server better. Keep up the good work.

1 Like