
/*
 * halfd admin_bot_kick extension for Admin Mod 2.10a.
 *
 * Allows kicking of bots via adminmod command without crashing the server.
 *
 * The following lines need to be added to your "admin.sma" file if you're
 * using adminmod 2.10 and want admin_bot_kick to work.
 *
 */
admin_bot_kick(kick_user[]) {
	new Text[MAX_TEXT_LENGTH];
	new strNum[MAX_NUMBER_LENGTH];
	new UserID = 0;
	
	if (CheckAuth(ACCESS_KICK)==0) {
		message(user,STRING_DENIED);
		return;
	}

	if ( check_user(kick_user) == 1) {
		get_userSessionID( kick_user, UserID );
		NumToStr( UserID, strNum );
		strncpy( Text, "BOT-KICK ", MAX_TEXT_LENGTH );
		strcat( Text, strNum );
		log( Text );
	} else {
		message(user,"Unrecognized player: ");
		message(user,kick_user);
	}
}


/* Add these lines at the bottom of admin.sma, where all the other "ParseCommand"
 * lines exist.
 *
 */
		else if(streq(ParseCommand, "admin_bot_kick")==1)
			admin_bot_kick(data);
