Fivem resource that limits car speed when tire bursts, good addition for role play server.
Speed limit can be easily changed at the top of client.lua file.
If more than one tire bursts speed decreases even more
You can change speed limit after burst at the top of client.lua file
Update 0.8.5
There were lots of if statements inside while loop which made the script to use lots client’s resources, this is now changed and should work a bit lighter
Decreased Speed limit delay, added delay configuration at the top of client.lua for easier access
holy cow what kind of cars are you using to have to worrie about that? there is not a straight away anywhere on the map that supports anything over 150, unless your 0-350 is in .00003 seconds hahaha just wondering.
You can change speed to whatever you want, this is in meters per second, so it would be a bit less than 100.0 if you want to limit to 350kmh.
Also you must write at least one 0 after decimal point, for example 100.0
Don’t write just 100
Citizen.CreateThread(function()
while true do
Citizen.Wait(0)
local me = GetPlayerPed(-1)
local veh = GetVehiclePedIsIn(me, false)
if DoesEntityExist(veh) then
SetVehicleMaxSpeed(veh, 20.0) -- set speed to what ever needed (this is im meters per second)
end
end
end)
There is also a way to limit each car through handling file
Nice Script dude. here is my idea to improve this script :
if car crashes (flip over and over ) when it has more than for example 100km speed it would be more realistic.
i think if you want to flip the car and show it like it is crashing its better to disable players control too. just saying.
Sure there is. Now trying to accurately portray a Konigsegg Agera RS top speed over slightly over 300MPH, and achieve it, that’s a bit more difficult to do with traffic enabled. But the Eastern Highway going north and south, it’s pretty achievable with no traffic.
I actually have created a similar script, but it is not perfect yet, i will release it soon. it disables the controls for a bit after crash, then adds a screen effect. The strength and duration of effect depends on how fast you were going before the crash and how much damage the car absorbed. I still need to fix it: the effect now appears with a small delay after the accident and i want to add blackout and controls disabling duration depending on speed demo