[Release] Realistic Vehicle Failure

anyone got it working good those days ? and have a right config ? please share it thank you

me and my fellow dev have managed to make some code to make the repair cost change dependant on how damaged the car is, if you can work out how to add a timer to them repairing i’ll be more than happy to swap our part for that :slight_smile:

I have been searching for this answer, have you tested esx_mecanojob with this? And if so, does it work properly without issue? I badly want to use this and I will rework whatever code I have to but if I can plug and play then that would be great

tested with what?
the mecanics can repair cars with the jobmenu.

That’s what I was asking, sorry for lack of better clarification and thank you for the reply.

How i can run source code, help me !!!

Is there a way that if people use the /fix or /repair that it repairs 50% of engine so stops smoking but they still need to see the mechanic.

As soon as i turn on your scripts, a few icons don’t have a name anymore or the names get shorted cut off.
Does anybody know what that problem could be ?

Anyone know how I might replace the tireBurstLottery function to a function where the tire will burst upon collision which is hard enough to disable the vehicle? Relatively new to this scene.

How to make that there is no smoke?

I just want to do it immediately fix engine for repair kit.

sorry for my bad english

Any notification if the player doesnt have money ?

Very nice script. Except, I wonder one thing. Maybe it’s stupid, but I can’t find it… How to adjust the price for repairing the vehicle at a workshop/repairshop?

Default there is no price to charge. The charge would happen on the server end (since you need to check the accounts from the server script)
You can come up with any way you want to figure out the charge. I made a calculation based on how much the vehicle was damaged (1000.0 - enginehealth) multiplied by a factor that seems appropriate.

You would have to create the check for money on the server side, and then push a notification either from the server, or make a call back to the client (TriggerClientEvent ) that creates the notification

sure. do SetEngineHealth to some value you want. The smoke from engine stops at any health above 300 i believe

Thanks for the information.
I will check that out.

how i can : Disable or remove other vehicle health scripts ? where ?

Another thing my friend. Since you trigger the event before, it still fix the car even without the money.
I’m so confused on how to run the check.

I mean if i have the money everything works fine. But when i dont have the money it still repairs the car.
Im also getting negative money.

can anyone help me how to disable /repair for everyone?

In the server lua is the location of the function for /repair
its a chat message event search.
to disable it you could always just comment out the entire function with a comment block:

 --[[   comment
  block
 ]]--