Diretional keys Problem
#1

I'm trying to detect the directional keys and can not.
I read something about my OS is windows vista but nothing concrete, then I wonder what is happening.
pawn Код:
public OnPlayerKeyStateChange(playerid,newkeys,oldkeys)
{
    new string[20];
    format(string,20,"KEY: %d OLDKEY: %d",newkeys,oldkeys);
    SendClientMessage(playerid,Sistema,string);
 
    if(newkeys & KEY_RIGHT)
    {
        if(GetPlayerSelState(playerid) > 0)
           SetPlayerSelectionID(playerid,GetPlayerSelectionID(playerid)+1);
        else
           return 1;
    }
    if(newkeys & KEY_LEFT)
    {
        if(GetPlayerSelState(playerid) > 0)
           SetPlayerSelectionID(playerid,GetPlayerSelectionID(playerid)-1);
        else
           return 1;
    }

    return 1;
}
I made debug, and when press the diretional keys, nothing happens, while the others wwere send via client message.
Reply


Messages In This Thread
Diretional keys Problem - by CyNiC - 05.09.2010, 16:17
Re: Diretional keys Problem - by [XST]O_x - 05.09.2010, 16:24
Re: Diretional keys Problem - by CyNiC - 05.09.2010, 16:30

Forum Jump:


Users browsing this thread: 1 Guest(s)