15.05.2014, 07:39
(
Последний раз редактировалось iFarbod; 15.05.2014 в 07:56.
Причина: ;
)
Virtual Key State Detection. See here for know what i mean
In Default , we can detect Keys like LMB, 2, C, ALT, MMB, Enter, Space, Q, E.
But with the Virtual Keys , we can detect keys like : F12, L, 8, BackSpace, Delete, N and ... Every Key is on your keyboard.
See it in Action:
In Default , we can detect Keys like LMB, 2, C, ALT, MMB, Enter, Space, Q, E.
But with the Virtual Keys , we can detect keys like : F12, L, 8, BackSpace, Delete, N and ... Every Key is on your keyboard.
pawn Код:
native GetVirtualKeyState(playerid, newkeys, oldkeys);
forward OnVirtualKeyStateChange(playerid, newkeys, oldkeys);
pawn Код:
public OnVirtualKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys & 35) // if pressed END
{
SetPlayerHealth(playerid, 0.0); // kill the player
}
return 1;
}