Jump to content
Sign in to follow this  
TAW_Yonose

Vehcile grip and speed

Recommended Posts

Hey, can someone help me make a vehicle go faster and more road grip that it wont slide so easy?

Share this post


Link to post
Share on other sites

something like this should suffice:

while {damage car < 1} do {
   _car = _this select 0;
   if(speed _car > 1) then {
   	_vel = velocity _car;
   	_down = 0.5; // experiment with this
   	_car setVelocity[_vel select 0, _vel select 1,(_vel select 2) - _down];
   	sleep 0.5; // experiment with this
   } else {
   	sleep 3;
   };
};

Share this post


Link to post
Share on other sites

i dont see any changes on the kart while im changing the _down and sleep

Share this post


Link to post
Share on other sites

ah, my bad. Had a small error in there.

_car = _this select 0;
while {damage _car < 1} do {
   if((speed _car > 1) && local _car) then {
       _vel = velocity _car;
       _down = 0.5; // experiment with this
       _car setVelocity[_vel select 0, _vel select 1,(_vel select 2) - _down];
       sleep 0.5; // experiment with this
   } else {
       sleep 3;
   };
}; 

put this in the init of your car:

nul = [this] execVM "thescriptfile.sqf";

It will also only apply the downforce while the car is moving.

Share this post


Link to post
Share on other sites

Alright but i still dont see any difference on the grip, will the ground like dirt or road have any effect on this?

Also when i had the sleep at 0.2 the kart where like jumping as it was loading each 0.2sec, but at sleep 1 i dident see any

what value should it be that i can see the differents?

Edited by TAW_Yonose

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×