AttackPlayerToPlayer?
#4

You can use OnPlayerUpdate or timer if OnPlayerUpdate is too fast
pawn Код:
new Jailed[MAX_PLAYERS]={999,...};
connect/disconnect
pawn Код:
if(Jailed[playerid] != 999)
    Jailed[Jailed[playerid]] = 999;
Jailed[playerid] = 999;
in /drag id
pawn Код:
Jailed[giveplyerid] = playerid;
pawn Код:
public OnPlayerUpdate(playerid)
{
    if(Jailed[playerid] != 999)
    {
        new Float:P[4];
        GetPlayerPos(Jailed[playerid],P[0],P[1],P[2]);
        GetPlayerFacingAngle(Jailed[playerid],P[3]);
        P[0] -= (2.5 * floatsin(-P[3], degrees));
        P[1] -= (2.5 * floatcos(-P[3], degrees));
        SetPlayerPos(playerid,P[0],P[1],P[2]);
        SetPlayerFacingAngle(playerid,P[3]);
    }
    return 1;
}
Reply


Messages In This Thread
AttackPlayerToPlayer? - by Gooday - 21.01.2012, 22:14
Re: AttackPlayerToPlayer? - by LiamM - 21.01.2012, 22:21
Re: AttackPlayerToPlayer? - by Gooday - 21.01.2012, 22:24
Re: AttackPlayerToPlayer? - by Jefff - 21.01.2012, 23:48

Forum Jump:


Users browsing this thread: 1 Guest(s)