Player not receiving prompt
#4

First of all:
Did you meant to do this?
Code:
if(!(IsACop(killerid) || IsAMember(killerid) || pInfo[playerid][pJailed] > 0 || pInfo[playerid][pAJailed] > 0 || Iter_Contains(Paintp, playerid) || pInfo[killerid][pMember] == 8 || vwp[playerid] == pInfo[playerid][pMember] || pInfo[playerid][pDuel] < INVALID_PLAYER_ID || (Event_Pos[0] == 0.0 && IsPlayerInRangeOfPoint(playerid, 140.0, Event_Pos[0], Event_Pos[1], Event_Pos[2]))))
The function will be executed if any of this checks returns false.

If you did, then try to debug your code on your own, let me give you and exemple:
pawn Code:
public OnPlayerDeath(playerid, killerid, reason)
{
if(killerid != INVALID_PLAYER_ID)
    {
            // pInfo[killerid][pKills]++;
            if(!IsACop(killerid)) return print("1");
            else if(!IsAMember(killerid)) return print("2");
            else if(!pInfo[playerid][pJailed] > 0) return print("3");
            else if(!pInfo[playerid][pAJailed] > 0) return print("4");
            else if(!Iter_Contains(Paintp, playerid)) return print("5");
            else if(!pInfo[killerid][pMember] == 8) return print("6");
            else if(!vwp[playerid] == pInfo[playerid][pMember]) return print("7");
            else if(!pInfo[playerid][pDuel] < INVALID_PLAYER_ID) return print("8");
            else if(!(Event_Pos[0] == 0.0 && IsPlayerInRangeOfPoint(playerid, 140.0, Event_Pos[0], Event_Pos[1], Event_Pos[2]))) return print("9");
            else return print("10");
            // {  Forget about the function for one sec
            //      pInfo[playerid][aVar][64] = killerid, pInfo[playerid][aSpam][7] = gtm+60;
            //      format(stmsg[playerid], 110, "Ai fost omorat de %s, ai 60 de secunde la dispozitie sa-l reclami folosind /call 112.", GetName(killerid));
            //      SendClientMessage(playerid, 0x60BF61FF, stmsg[playerid]);
            // }
            return 1;
}
Try to compile it and see wich number is printed in the console, then resolve your bugs.
If it doesn't compile, read the code and figure out the error yourself because all i did was try to make your code a little bit better.
Reply


Messages In This Thread
Player not receiving prompt - by Maheegan - 07.11.2018, 02:31
Re: Player not receiving prompt - by cSharp - 07.11.2018, 04:34
Re: Player not receiving prompt - by KinderClans - 07.11.2018, 08:27
Re: Player not receiving prompt - by Ermanhaut - 07.11.2018, 10:53

Forum Jump:


Users browsing this thread: 1 Guest(s)