SA-MP Forums Archive
help pl0x :) - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: help pl0x :) (/showthread.php?tid=65332)



help pl0x :) - Think - 11.02.2009

hey i made a lil command in a FS but when i join my server and type /login lol its says USAGE: /ignore [playerid]

pawn Код:
if(strcmp(cmd, "/ignore", true) == 0)
    {
      tmp = strtok(cmdtext, idx);
        if(!strlen(tmp))
        {
            SendClientMessage(playerid, 0xB4B5B7FF, "USAGE: /ignore [playerid]");
            return 1;
        }
        giveplayerid = strval(tmp);
        GetPlayerName(giveplayerid,playername,sizeof(playername));
        if(IsPlayerConnected(giveplayerid))
        {
            if (negeer[playerid][giveplayerid] == 0)
            {
              negeer[playerid][giveplayerid] = 1;
              format(string, 128, "You ignored %s. You won't see any PMs of him anymore.", playername);
              SendClientMessage(playerid, 0xFF0000AA, string);
            }
            else if(negeer[playerid][giveplayerid] >= 1)
            {
              negeer[playerid][giveplayerid] = 0;
              format(string, 128, "You have stopped ignoring %s. You will now see his PMs again.", playername);
              SendClientMessage(playerid, 0xFF0000AA, string);
            }
        }
        else
        {
            format(string, 128, "%d is not connected!", giveplayerid);
            SendClientMessage(playerid, 0xFF0000AA, string);
            return 1;
        }
        return 1;
    }



Re: help pl0x :) - Danut - 11.02.2009

rofl , post all the COMMAND


Re: help pl0x :) - Think - 11.02.2009

Quote:
Originally Posted by Danut
rofl , post all the COMMAND
updated.


Re: help pl0x :) - Think - 12.02.2009

Quote:
Originally Posted by Danut
rofl , post all the COMMAND
well..


Re: help pl0x :) - Born2die - 12.02.2009

Because you made it like this: If /ignore doesn't match, say USAGE: /ignore [playerid].
But I'm not able to correct that script sry lol.


Re: help pl0x :) - boylett - 12.02.2009

Post your /login command aswell.


Re: help pl0x :) - Think - 12.02.2009

Quote:
Originally Posted by !fruit ? "Boylett" : "Boyberry"
Post your /login command aswell.
its with all the commands.. even with /adgasdgadgadg (wich i even dind't made..)


Re: help pl0x :) - boylett - 12.02.2009

Quote:
Originally Posted by Pandabeer1337
Quote:
Originally Posted by !fruit ? "Boylett" : "Boyberry"
Post your /login command aswell.
its with all the commands.. even with /adgasdgadgadg (wich i even dind't made..)
You haven't posted it though, only /ignore :P


Re: help pl0x :) - Think - 12.02.2009

Quote:
Originally Posted by !fruit ? "Boylett" : "Boyberry"
Quote:
Originally Posted by Pandabeer1337
Quote:
Originally Posted by !fruit ? "Boylett" : "Boyberry"
Post your /login command aswell.
its with all the commands.. even with /adgasdgadgadg (wich i even dind't made..)
You haven't posted it though, only /ignore :P
pawn Код:
if (strcmp(cmd, "/login", true) ==0 )
    {
        new tmppass[64];
        if (gPlayerLogged[playerid] == 1)
        {
            SendClientMessage(playerid, COLOR_WHITE, "SERVER: You are already logged in.");
            return 1;
        }
        tmp = strtok(cmdtext, idx);
        if(!strlen(tmp))
        {
            SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /login [password]");
            return 1;
        }
        strmid(tmppass, tmp, 0, strlen(cmdtext), 255);
        Encript(tmppass);
        if (gdebug){printf("DEBUG enterd %s", tmppass);}
        OnPlayerLogin(playerid,tmppass);
        return 1;
    }



Re: help pl0x :) - boylett - 12.02.2009

Well I cant see any reason why /login would cause /ignore to trigger