Hotkey Help
#8

Quote:
Originally Posted by BroZeus
Посмотреть сообщение
it should be
pawn Код:
public OnPlayerKeyStateChange( playerid, newkeys, oldkeys )
{
    if ( IsPlayerInAnyVehicle( playerid ) )
    {
        if ( (newkeys & KEY_YES) !(oldkeys & KEY_YES) )
        {
            new Float: zAng;
            GetVehicleZAngle( GetPlayerVehicleID( playerid ), zAng );
            SetVehicleZAngle( GetPlayerVehicleID( playerid ), zAng );
            GameTextForPlayer( playerid, "~r~Vehicle Flipped!", 3000, 3 );
        }
    }
    return 1;
}
the code u sing will work but it will have bugs use the above one see the changes in "if" line
the bug is that if the y key is being pressed and during it has been presed and some other key is pressed then the vehicle will flip again read https://sampwiki.blast.hk/wiki/OnPlayerKeyStateChange carefully
I get error's using that!
Reply


Messages In This Thread
Hotkey Help - by Proximo - 11.05.2014, 14:57
Re: Hotkey Help - by Parallex - 11.05.2014, 15:50
Re: Hotkey Help - by Konstantinos - 11.05.2014, 16:13
Re: Hotkey Help - by Proximo - 12.05.2014, 07:26
Re: Hotkey Help - by Scottas - 12.05.2014, 08:10
Re: Hotkey Help - by Proximo - 12.05.2014, 09:08
Re: Hotkey Help - by BroZeus - 12.05.2014, 09:13
Re: Hotkey Help - by Proximo - 12.05.2014, 11:05

Forum Jump:


Users browsing this thread: 2 Guest(s)