key fire
#1

Hi,

How to detect all key fire? key_Fire only detect when press key_fire, but i want all keys, when player could shoot
Reply
#2

KEY_FIRE is when a player presses a key used to shoot, it doesn't matter what key it is, it's still KEY_FIRE if the key makes you shoot... Eh, you could just test instead of asking every single small thing here...
Reply
#3

So with getplayerkeys, i need just KEY_FIRE? but i test i prints, when i run and shoot, when c and shoot, i always get different keys
Reply
#4

Read this: https://sampwiki.blast.hk/wiki/OnPlayerKeyStateChange
Specifically the part about "how NOT to check for a key".
Reply
#5

So, getplayerkeys(key,left,right);

if( key & KEY_FIRE )
{

}

?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)