IRCCMD:say(botid, channel[], user[], host[], params[])
{
if (IRC_IsOwner(botid, channel, user))
{
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02*** Owner %s on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "*** Owner %s on IRC: %s", user, params);
SendClientMessageToAll(0x0000FFFF, msg);
}
}
else if (IRC_IsAdmin(botid, channel, user))
{
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02*** Management %s on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "*** Management %s on IRC: %s", user, params);
SendClientMessageToAll(0x0000FFFF, msg);
}
}
else if (IRC_IsHalfop(botid, channel, user)) // back
{
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02*** Admin %s on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "*** Admin %s on IRC: %s", user, params);
SendClientMessageToAll(0x0000FFFF, msg);
}
}
else if (IRC_IsVoice(botid, channel, user))
{
// Check if the user entered any text
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02*** %s on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "*** %s on IRC: %s", user, params);
SendClientMessageToAll(0x0000FFFF, msg);
}
}
return 1;
}
D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3199) : error 001: expected token: "-string end-", but found "-identifier-" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3199) : error 001: expected token: ";", but found "[" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3201) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3203) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3207) : error 021: symbol already defined: "format" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3213) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3215) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3217) : error 021: symbol already defined: "msg" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3219) : error 021: symbol already defined: "format" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3225) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3227) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3229) : error 021: symbol already defined: "msg" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3231) : error 021: symbol already defined: "format" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3237) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3240) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3242) : error 021: symbol already defined: "msg" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3244) : error 021: symbol already defined: "format" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3250) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3258) : warning 203: symbol is never used: "connectionHandle" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3258) : warning 203: symbol is never used: "msg" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 18 Errors.
IRCCMD:say(botid, channel[], user[], host[], params[]) { new msg[150]; if (IRC_IsOwner(botid, channel, user)) { if (!isnull(params)) { // Echo the formatted message format(msg, sizeof(msg), "02*** Owner %s on IRC: %s", user, params); IRC_GroupSay(groupID, channel, msg); format(msg, sizeof(msg), "*** Owner %s on IRC: %s", user, params); SendClientMessageToAll(0x0000FFFF, msg); } } else if (IRC_IsAdmin(botid, channel, user)) { if (!isnull(params)) { // Echo the formatted message format(msg, sizeof(msg), "02*** Management %s on IRC: %s", user, params); IRC_GroupSay(groupID, channel, msg); format(msg, sizeof(msg), "*** Management %s on IRC: %s", user, params); SendClientMessageToAll(0x0000FFFF, msg); } } else if (IRC_IsHalfop(botid, channel, user)) {//back if (!isnull(params)) { // Echo the formatted message format(msg, sizeof(msg), "02*** Admin %s on IRC: %s", user, params); IRC_GroupSay(groupID, channel, msg); format(msg, sizeof(msg), "*** Admin %s on IRC: %s", user, params); SendClientMessageToAll(0x0000FFFF, msg); } } else if (IRC_IsVoice(botid, channel, user)) { // Check if the user entered any text if (!isnull(params)) { // Echo the formatted message format(msg, sizeof(msg), "02*** %s on IRC: %s", user, params); IRC_GroupSay(groupID, channel, msg); format(msg, sizeof(msg), "*** %s on IRC: %s", user, params); SendClientMessageToAll(0x0000FFFF, msg); } } return true; }
botid, channel[], user[], host[], params[]
IRCCMD:say(botid, channel[], user[], host[], params[])
{
if(isnull(params))
return 1;
new
mode[2],
title[16] = "",
msg[128];
IRC_GetUserChannelMode(botid, channel, user, mode);
switch(mode[0])
{
case '~': title = "Owner ";
case '&': title = "Super Op ";
case '@': title = "Op ";
case '%': title = "Half Op ";
case '+': title = "Voice ";
}
format(msg, sizeof(msg), "02*** %s%s on IRC: %s", title, user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "*** %s%s on IRC: %s", title, user, params);
SendClientMessageToAll(0x0000FFFF, msg);
return 1;
}
Look all from this: IRCCMD
![]() Any code have (botid,channel[],user[],host[],params[]) gives these errors |
IRCCMD:say(botid, channel[], user[], host[], params[])
{
if (IRC_IsOwner(botid, channel, user))
{
// Check if the user entered any text
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02Owner(%s) on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "**Owner(%s): %s", user, params);
SendClientMessageToAll(COLOR_BLUE, msg);
}
return 1;
}
if (IRC_IsAdmin(botid, channel, user))
{
// Check if the user entered any text
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02Manager(%s) on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "**Manager(%s): %s", user, params);
SendClientMessageToAll(COLOR_BLUE, msg);
}
return 1;
}
if (IRC_IsOp(botid, channel, user))
{
// Check if the user entered any text
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02Admin(%s) on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "*Admin(%s): %s", user, params);
SendClientMessageToAll(COLOR_BLUE, msg);
}
return 1;
}
if (IRC_IsHalfop(botid, channel, user))
{
// Check if the user entered any text
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02Moderator(%s) on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "*Moderator(%s): %s", user, params);
SendClientMessageToAll(COLOR_BLUE, msg);
}
return 1;
}
// Check if the user has at least voice in the channel
if (IRC_IsVoice(botid, channel, user))
{
// Check if the user entered any text
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02*VIP(%s) on IRC: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "VIP(%s): %s", user, params);
SendClientMessageToAll(COLOR_ORANGE, msg);
}
return 1;
}
else
{
if (!isnull(params))
{
new msg[128];
// Echo the formatted message
format(msg, sizeof(msg), "02[-] 07%s: %s", user, params);
IRC_GroupSay(groupID, channel, msg);
format(msg, sizeof(msg), "[-] %s: %s", user, params);
SendClientMessageToAll(-1, msg);
}
return 1;
}
}
this is mine (from my gamemode) and it's complie fine try it
PHP код:
|
D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3183) : error 001: expected token: "-string end-", but found "-identifier-" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3183) : error 001: expected token: ";", but found "[" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3184) : error 001: expected token: "-string end-", but found "-identifier-" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3184) : error 029: invalid expression, assumed zero D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3187) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3201) : error 001: expected token: "-string end-", but found "-identifier-" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3201) : error 001: expected token: ";", but found "[" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3203) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3206) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3210) : error 021: symbol already defined: "format" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3215) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3217) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3220) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3222) : error 021: symbol already defined: "msg" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3224) : error 021: symbol already defined: "format" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3229) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3231) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3234) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3236) : error 021: symbol already defined: "msg" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3238) : error 021: symbol already defined: "format" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3243) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3245) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3248) : error 010: invalid function or declaration D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3250) : error 021: symbol already defined: "msg" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3252) : error 021: symbol already defined: "format" D:\samp folder\(XteMeS) xMs\gamemodes\xMs.pwn(3257) : error 010: invalid function or declaration Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 26 Errors.