Unknown command.
#1

Hello guys.I scripted my server last summer and now I restarted scripting it.I compiled it into 0.3x and till than,many things are not working properly.
One of them is,for example this command ( there are more commands with same behaviour ):

Код:
CMD:clubkick( playerid, params[ ] )
{
 	if ( GetPVarInt( playerid, "AdminLevel" ) < 2 )
	    return SendClientMessage( playerid, -1, "You must be an "AdminLevel2"{FFFFFF} to team kick someone.");

 	if ( sscanf( params, "us[80]", params[ 0 ], params[ 1 ] ) )
	    return SendClientMessage( playerid, -1, "Usage: /clubkick [id] [reason]");

	if ( !IsPlayerConnected( params[ 0 ] ) )
	    return SendClientMessage( playerid, -1, ""COLOR_RED"Player is not connected");


    if(GetPVarInt(params[ 0 ],"Club") == 1)
    {
		HitmanM--;
		SaveTeamLimits();
		new string[ 128 ];
		format(string, sizeof(string), "%s "BLUESV"has been Club kicked by "REDSV"%s "BLUESV"[Reason: "REDSV"%s"BLUESV"]",pName(params[ 0 ]),pName(playerid), params[ 1 ]);
	    SendClientMessageToAll(REDS, string);

		SetPVarInt(params[ 0 ],"Club",0);
		SpawnPlayer(params[ 0 ]);
    }
    else if(GetPVarInt(params[ 0 ],"Club") == 2)
    {
		NFSM--;
		SaveTeamLimits();
		new string[ 128 ];
		format(string, sizeof(string), "%s "BLUESV"has been Club kicked by "REDSV"%s "BLUESV"[Reason: "REDSV"%s"BLUESV"]",pName(params[ 0 ]),pName(playerid), params[ 1 ]);
	    SendClientMessageToAll(REDS, string);

		SetPVarInt(params[ 0 ],"Club",0);
		SpawnPlayer(params[ 0 ]);
    }
    else if(GetPVarInt(params[ 0 ],"Club") == 3)
    {
		MotoM--;
		SaveTeamLimits();
		new string[ 128 ];
		format(string, sizeof(string), "%s "BLUESV"has been Club kicked by "REDSV"%s "BLUESV"[Reason: "REDSV"%s"BLUESV"]",pName(params[ 0 ]),pName(playerid), params[ 1 ]);
	    SendClientMessageToAll(REDS, string);

		SetPVarInt(params[ 0 ],"Club",0);
		SpawnPlayer(params[ 0 ]);
    }
	return 1;
}
After I use it,I get unknown command,my skin changes but nothing more happens.

Ideas?
Reply
#2

get any errors ?
Reply
#3

no errors
Reply
#4

by the way,I have seen some topics with same problem,but they are using mysql.They get unknown command,same like me.But Im using y_ini.

I forgot to tell you that my saving system has some problems.Sometimes it is not loading my stats.This can cause my problem?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)