GetRearOfVehicle
#12

You need to get the vehicleid of the vehicle, then use this code.
Код:
new Float:x, Float:y, Float:z, Float:a, Float:x2, Float:y2;
GetVehiclePos(vehicleid, x, y, z);
GetVehicleZAngle(vehicleid, a);
x2 = x + (-6 * floatsin(-a, degrees));
y2 = y + (-6 * floatcos(-a, degrees));
SetPlayerCheckpoint(playerid, x2, y2, z, 1.5);
Clear to understand, this will place a checkpoint at the back of the vehicle.

I think the floatsin and floatcos part of the code is by Y-Less.
Reply


Messages In This Thread
GetRearOfVehicle - by cepiokas - 02.12.2010, 12:23
Re: GetRearOfVehicle - by Ash. - 02.12.2010, 12:40
Re: GetRearOfVehicle - by cepiokas - 02.12.2010, 12:48
Re: GetRearOfVehicle - by cepiokas - 02.12.2010, 13:00
Re: GetRearOfVehicle - by cepiokas - 02.12.2010, 13:07
Re: GetRearOfVehicle - by Ash. - 02.12.2010, 13:14
Re: GetRearOfVehicle - by cepiokas - 02.12.2010, 13:15
Re: GetRearOfVehicle - by armyoftwo - 02.12.2010, 13:17
Re: GetRearOfVehicle - by cepiokas - 02.12.2010, 13:20
Re: GetRearOfVehicle - by Ash. - 02.12.2010, 13:22
Re: GetRearOfVehicle - by armyoftwo - 02.12.2010, 13:22
Re: GetRearOfVehicle - by Rac3r - 02.12.2010, 13:24
Re: GetRearOfVehicle - by cepiokas - 02.12.2010, 13:58

Forum Jump:


Users browsing this thread: 6 Guest(s)