SA-MP Forums Archive
The aim and shift shake hands raise the targeted - 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: The aim and shift shake hands raise the targeted (/showthread.php?tid=504219)



The aim and shift shake hands raise the targeted - gmstrikker - 02.04.2014

I saw here in the forum mt time and trying to do ...
If I'm aiming for a guy and I shift shake the guy being automatically targeted the ta /handsup

I tried to do so, but I do qnd commands nothing happens:

pawn Код:
public OnPlayerKeyStateChange(playerid,newkeys,oldkeys)
{

// render jogador

    new targetplayer = GetPlayerTargetPlayer(playerid); // Store the ID
    if (PRESSED(KEY_JUMP) && PRESSED(KEY_SECONDARY_ATTACK )) {
        if(targetplayer != INVALID_PLAYER_ID){
            //SendClientMessage(playerid, COLOR_BLACKRED, "Vocк precisa de dois jogadores da mesma organizaзгo mirando para render uma vitima!");
            SendClientMessage(playerid, COLOR_BLACKRED, "<!> Jogador rendido!");
            SendClientMessage(targetplayer, COLOR_BLACKRED, "Vocк foi rendido por outro jogador");
            SendClientMessage(targetplayer, COLOR_BLACKRED, "Nгo reaja ao assalto/sequestro ou poderб ser punido por CK (50 horas preso) se morrer");
            SetPlayerSpecialAction(targetplayer,SPECIAL_ACTION_HANDSUP);
        }
    }



Re: The aim and shift shake hands raise the targeted - gmstrikker - 03.04.2014

any can help me?


Re: The aim and shift shake hands raise the targeted - gmstrikker - 04.04.2014

anyy?


Re: The aim and shift shake hands raise the targeted - Jefff - 04.04.2014

Try
pawn Код:
if(PRESSED(KEY_JUMP | KEY_SECONDARY_ATTACK))



Re: The aim and shift shake hands raise the targeted - gmstrikker - 05.04.2014

But then in this case would not change:
Aiming and tighten shift
for
Mirando or by pressing shift

I wanted it to work when the player was aiming, and tightens up the shift

Nobody knows why it is not working?


Re: The aim and shift shake hands raise the targeted - gmstrikker - 06.04.2014

jefff? ANYYYYYYYYYYYY!?


Re: The aim and shift shake hands raise the targeted - Binx - 06.04.2014

I don't understand what you want to do. When you press shift, he does what? Automatically does "/handsup"?


Re: The aim and shift shake hands raise the targeted - Jefff - 06.04.2014

pawn Код:
if(PRESSED(KEY_HANDBRAKE | KEY_SPRINT))
    {
        new targetplayer = GetPlayerTargetPlayer(playerid); // Store the ID
        if(targetplayer != INVALID_PLAYER_ID)
        {
            //SendClientMessage(playerid, COLOR_BLACKRED, "Voce^ precisa de dois jogadores da mesma organizaзa~o mirando para render uma vitima!");
            SendClientMessage(playerid, COLOR_BLACKRED, "<!> Jogador rendido!");
            SendClientMessage(targetplayer, COLOR_BLACKRED, "Voce^ foi rendido por outro jogador");
            SendClientMessage(targetplayer, COLOR_BLACKRED, "Na~o reaja ao assalto/sequestro ou poderб ser punido por CK (50 horas preso) se morrer");
            SetPlayerSpecialAction(targetplayer,SPECIAL_ACTION_HANDSUP);
        }
    }