SA-MP Forums Archive
flip cmd - 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)
+--- Thread: flip cmd (/showthread.php?tid=291535)



flip cmd - niels44 - 20.10.2011

hello,
can someone make a flip cmd for me with strcmp? i need it for my server XD
thnx
niels


Re: flip cmd - SmiT - 20.10.2011

If you mean a "flip" command for the vehicle, here is one :
pawn Код:
if ( !strcmp( "/flip", cmdtext, true, 10) )
{
    new
        Float: P[ 4 ];
    GetPlayerPos( playerid, P[ 0 ], P[ 1 ], P[ 2 ] );
    GetVehicleZAngle( GetPlayerVehicleID( playerid ) , P[ 3 ]);  
    SetVehiclePos( GetPlayerVehicleID( playerid ), P[ 0 ], P[ 1 ], P[ 2 ] );
    SetVehicleZAngle( GetPlayerVehicleID( playerid ), P[ 3 ] );
    return true;
}



Re: flip cmd - CrunkBankS - 20.10.2011

pawn Код:
new playerstate = GetPlayerState(playerid);
    if(playerstate == PLAYER_STATE_DRIVER)
    {
        new VehicleID,Float:B;
        VehicleID = GetPlayerVehicleID(playerid);
        GetVehicleZAngle(VehicleID,B);
        SetVehicleZAngle(VehicleID,B);
    }



Re: flip cmd - niels44 - 20.10.2011

thnx guys XD added rep