IRC problem
#1

Hi guys I created IRC system but I have a problem i try to !kick someone , but I can only kick a person who is online in IRC so i want to kick a player in-game

Код:
!kick
-ChanServ- Insufficient parameters for KICK.
-ChanServ- Syntax: KICK <#channel> <nickname> [reason]
pawn code :

Код:
IRCCMD:kick(botid, channel[], user[], host[], params[])
{
	// Check if the user is at least a halfop in the channel
	if (IRC_IsHalfop(botid, channel, user))
	{
		new playerid, reason[64];
		// Check if the user at least entered a player ID
		if (sscanf(params, "dS(No reason)[64]", playerid, reason))
		{
			return 1;
		}
		// Check if the player is connected
		if (IsPlayerConnected(playerid))
		{
			// Echo the formatted message
			new msg[128], name[MAX_PLAYER_NAME];
			GetPlayerName(playerid, name, sizeof(name));
			format(msg, sizeof(msg), "02*** %s has been kicked by %s on IRC. (%s)", name, user, reason);
			IRC_GroupSay(groupID, channel, msg);
			format(msg, sizeof(msg), "*** %s has been kicked by %s on IRC. (%s)", name, user, reason);
			SendClientMessageToAll(0x0000FFFF, msg);
			// Kick the player
			Kick(playerid);
		}
	}
	return 1;
}
Reply
#2

Change your cmd to 'akick' and re-compile your script.

By doing !kick you're executing IRC command not the in-game (FS) one.
Reply
#3

I need to change cmd to akick in fs and in gamemode ?
Reply
#4

-ChanServ- Insufficient parameters for AKICK.
-ChanServ- Syntax: AKICK <#channel> <ADD|DEL|LIST> [parameters]

Bingo what to do now ?
Reply
#5

No wait, My bad appologies.

Actually the cmd itself is made to kick users on IRC not in-game.
Reply
#6

Try changing your command name to like, 'ikick' and then recompile it.
Reply
#7

Turn off fantasy commands in your channel if you do not want to meddle with your gamemode (/cs help set).
Reply
#8

I dont know what to do What to do when i try /cs help ?
Reply
#9

Vince how can I contact with u ?
Reply
#10

Finished Thank you guys all
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)