DzMG-LV Posted November 21, 2015 Share Posted November 21, 2015 So i want make for my RP server script when you drive 10k miles, tire's will blow up. Sometimes front left/right, sometimes rear right/left for that i will use math.random function. But how can i make when exactly you have driven 10k miles the tire will blow? Link to comment
Addlibs Posted November 21, 2015 Share Posted November 21, 2015 You'd need an milage counter, first of all. If you already have one, examine how it saves the milage and then simply check if 10,000 mi was reached every now and then (or through events, preferably). Link to comment
jingzhi Posted November 23, 2015 Share Posted November 23, 2015 So i want make for my RP server script when you drive 10k miles, tire's will blow up. Sometimes front left/right, sometimes rear right/left for that i will use math.random function. But how can i make when exactly you have driven 10k miles the tire will blow? Use getElementPosition() setTimer() This won't give you the most precise mileage (should be smaller than the actual number), but it also won't cause any lag Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now