SA-MP Forums Archive
Improve this /flip - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Improve this /flip (/showthread.php?tid=138171)



Improve this /flip - Majataka - 31.03.2010

Код:
  if(strcmp(cmdtext, "/flip", true) == 0)
  {
    new currentveh;
    currentveh = GetPlayerVehicleID(playerid);
		SetVehicleZAngle(currentveh, 0);
		SendClientMessage(playerid, 0xFFFFFFFF, "Your vehicle has been flipped.");
    return 1;
  }
When i /flip the car gets back on it wheels with the speed it had but the front of the car is facing North all the time what is stupid D: any ways of fixing it? I don't want /flip that stops the car


Re: Improve this /flip - wafffllesss - 31.03.2010

Try that
pawn Код:
if(strcmp(cmdtext, "/flip", true) == 0)
  {
    new currentveh,Float:ang;
    currentveh = GetPlayerVehicleID(playerid);
        GetVehicleZAngle(currentveh,ang);
        SetVehicleZAngle(currentveh, ang+0.5);
        SendClientMessage(playerid, 0xFFFFFFFF, "Your vehicle has been flipped.");
    return 1;
  }



Re: Improve this /flip - Majataka - 31.03.2010

Quote:
Originally Posted by wafffllesss
Try that
pawn Код:
if(strcmp(cmdtext, "/flip", true) == 0)
  {
    new currentveh,Float:ang;
    currentveh = GetPlayerVehicleID(playerid);
        GetVehicleZAngle(currentveh,ang);
        SetVehicleZAngle(currentveh, ang+0.5);
        SendClientMessage(playerid, 0xFFFFFFFF, "Your vehicle has been flipped.");
    return 1;
  }