SA-MP Forums Archive
IRC Bot problem [Rep +] - 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: IRC Bot problem [Rep +] (/showthread.php?tid=311355)



IRC Bot problem [Rep +] - Zhoom - 16.01.2012

Hello guys, how can I do something like this on IRC:

pawn Код:
enum PlayerData
{
    Test,
};
new PlayerInfo[MAX_PLAYERS][PlayerData];

I added this under my IRCCMD:slap
PlayerInfo[user][Test] = 0;
I tried this and failed
im using incognito's irc plugin

help me guys! + rep


Re: IRC Bot problem [Rep +] - Zhoom - 16.01.2012

and if this script is not possible to work, can you guys tell me how to script it so that the functions will be the same


Re: IRC Bot problem [Rep +] - Zhoom - 16.01.2012

*Bump*
what should I replace [MAX_PLAYERS] with?
on IRC for 'user'


Re: IRC Bot problem [Rep +] - Konstantinos - 16.01.2012

pawn Код:
new
     PlayerInfo[ MAX_PLAYERS ][ PlayerData ];

// ---

IRCCMD:test(botid, channel[], user[], host[], params[])
{
    PlayerInfo[user][Test] = 0;
    return 1;
}
// ---
IRCCMD:test2(botid, channel[], user[], host[], params[])
{
    if(PlayerInfo[user][Test] == 0)
    {
        IRC_GroupNotice(gGroupID, user, "It works!");
    }
    return 1;
}



Re: IRC Bot problem [Rep +] - Zhoom - 16.01.2012

Quote:

error 033: array must be indexed (variable "user")

help me please


Re: IRC Bot problem [Rep +] - Konstantinos - 16.01.2012

Line?


Re: IRC Bot problem [Rep +] - Zhoom - 16.01.2012

pawn Код:
both of these:
PlayerInfo[user][Test] = 0;



Re: IRC Bot problem [Rep +] - [ABK]Antonio - 16.01.2012

What exactly do you need it for?


Re: IRC Bot problem [Rep +] - Min - 16.01.2012

well I want to make a user can only use this command 3 times.

EDITED:
P.S: Zhoom is my little cousin, he was using my laptop to post this. *facepalm*


Re: IRC Bot problem [Rep +] - Zhoom - 16.01.2012

Quote:
Originally Posted by Min
Посмотреть сообщение
well I want to make a user can only use this command 3 times.

EDITED:
P.S: Zhoom is my little cousin, he was using my laptop to post this. *facepalm*
lol sorry Min i forgot to logout ur acc xD

ok dwane that is not the problem, it happens on this line:

pawn Код:
PlayerInfo[user][Test] = 0;
and
if(PlayerInfo[user][Test] == 0)