ABS Braking System Script help
#4

Try this function

Код:
stock SetVehicleSpeed(vehicleid, Float:speed)
{
	new Float:x1, Float:y1, Float:z1, Float:x2, Float:y2, Float:z2, Float:a;
	GetVehicleVelocity(vehicleid, x1, y1, z1);
	GetVehiclePos(vehicleid, x2, y2, z2);
	GetVehicleZAngle(vehicleid, a); a = 360 - a;
	x1 = (floatsin(a, degrees) * (speed/100) + floatcos(a, degrees) * 0 + x2) - x2;
	y1 = (floatcos(a, degrees) * (speed/100) + floatsin(a, degrees) * 0 + y2) - y2;
	SetVehicleVelocity(vehicleid, x1, y1, z1);
}
from
https://sampforum.blast.hk/showthread.php?tid=307052
Reply


Messages In This Thread
ABS Braking System Script help - by BrightLeaN - 08.09.2018, 19:17
Re: ABS Braking System Script help - by Infin1ty - 09.09.2018, 09:33
Re: ABS Braking System Script help - by BrightLeaN - 09.09.2018, 17:02
Re: ABS Braking System Script help - by ShihabSoft - 09.09.2018, 19:32
Re: ABS Braking System Script help - by Sithis - 10.09.2018, 11:37

Forum Jump:


Users browsing this thread: 1 Guest(s)