SA-MP Forums Archive
IRC help - 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 help (/showthread.php?tid=535658)



IRC help - Affan - 05.09.2014

Error:
pawn Код:
pandora/irc/irc.pwn(153) : error 001: expected token: "-string end-", but found "-identifier-"
pandora/irc/irc.pwn(153) : error 001: expected token: ";", but found "["
pandora/irc/irc.pwn(155) : error 010: invalid function or declaration
pandora/irc/irc.pwn(157) : error 010: invalid function or declaration
pandora/irc/irc.pwn(165) : error 010: invalid function or declaration
Lines 153 - 165
pawn Код:
IRCCMD:say(botid, channel[], user[], host[], params[])
{
    if (IRC_IsVoice(botid, channel, user))
    {
        if (!isnull(params))
        {
            format(string, sizeof(string), "02 %s on IRC: %s", user, params);
            IRC_GroupSay(groupID, channel, string);
            format(string, sizeof(string), ""CLIGHT"%s on IRC: {FFFFFF}%s", user, params);
            SendClientMessageToAll(0x0000FFFF, msg);
        }
    }
    return 1;



Re: IRC help - Mohamedilham - 05.09.2014

iam also got that error


Re: IRC help - Affan - 06.09.2014

Bump


Re: IRC help - Affan - 08.09.2014

Bump, really need help with this.


Re: IRC help - Mic_H - 08.09.2014

Код:
IRCCMD:say(botid, channel[], user[], host[], params[])
{
    if (IRC_IsVoice(botid, channel, user))
    {
        if (!isnull(params))
        {
            format(string, sizeof(string), "02 %s on IRC: %s", user, params);
            IRC_GroupSay(groupID, channel, string);
            format(string, sizeof(string), ""CLIGHT"%s on IRC: {FFFFFF}%s", user, params);
            SendClientMessageToAll(0x0000FFFF, msg);
        }
    }
    return 1;
}
Please //Tag the Lines showing error..


Re: IRC help - M0HAMMAD - 08.09.2014

pawn Код:
IRCCMD:say(botid, channel[], user[], host[], params[])
{
    if (IRC_IsVoice(botid, channel, user))
    {
        if (!isnull(params))
        {
            // Echo the formatted message
            new msg[112];
            format(msg,sizeof(msg), "(IRC) %s: %s", user, params);
            SendClientMessageToAll(COLOR_LIGHTBLUE, msg);
            format(msg, sizeof(msg),"(IRC) %s: %s", user, params);
            Say(channel,msg);
        }
    }
    return 1;
}
And IRC Include : [Change format .pwn To .inc]


Re: IRC help - Affan - 09.09.2014

@M0HAMMAD : That seemed to cause more errors:

pawn Код:
pandora/irc/irc.pwn(156) : error 001: expected token: "-string end-", but found "-identifier-"
pandora/irc/irc.pwn(156) : error 001: expected token: ";", but found "["
pandora/irc/irc.pwn(158) : error 010: invalid function or declaration
pandora/irc/irc.pwn(160) : error 010: invalid function or declaration
pandora/irc/irc.pwn(164) : error 021: symbol already defined: "format"
pandora/irc/irc.pwn(168) : error 054: unmatched closing brace ("}")
pandora/irc/irc.pwn(170) : error 010: invalid function or declaration
pawn Код:
IRCCMD:say(botid, channel[], user[], host[], params[])//156
{//157
    if (IRC_IsVoice(botid, channel, user))//158
    {//159
        if (!isnull(params))//160
        {//161
            // Echo the formatted message // 162
            new msg[112]; // 163
            format(msg,sizeof(msg), "(IRC) %s: %s", user, params); // 164
            SendClientMessageToAll(COLOR_LIGHTBLUE, msg); // 165
            format(msg, sizeof(msg),"(IRC) %s: %s", user, params); // 166
            Say(channel,msg); // 167
        } // 168
    } // 169
    return 1; // 170
}// 171



Re: IRC help - Flake. - 09.09.2014

pawn Код:
IRCCMD:say(botid, channel[], user[], host[], params[])
{
    if (IRC_IsVoice(botid, channel, user))
    {
        if (!isnull(params))
        {
            new string[64], msg[64];
            format(string, sizeof(string), "02 %s on IRC: %s", user, params);
            IRC_GroupSay(groupID, channel, string);
            format(string, sizeof(string), "%s on IRC: {FFFFFF}%s", user, params);
            SendClientMessageToAll(0x0000FFFF, msg);
        }
    }
    return 1;
}
This will work, you've got an issue with your embedded color.


Re: IRC help - Affan - 09.09.2014

Still giving the same errors. I wonder why, I used this same command in another script, yet it works perfectly fine.


Re: IRC help - Flake. - 09.09.2014

Quote:
Originally Posted by Affan
Посмотреть сообщение
Still giving the same errors. I wonder why, I used this same command in another script, yet it works perfectly fine.
Then it's a problem with the include.