RCON only
#1

Heyy guys i have problem with some command. IDK how can i set them only for RCON.Look at this one.
Код:
// Repairs the player's vehicle
COMMAND:repair(playerid, params[])
{
	// Send the command to all admins so they can see it
	SendAdminText(playerid, "/repair", params);

	// Check if the player has logged in
	if (APlayerData[playerid][LoggedIn] == true)
	{
		// Check if the player's admin-level is at least 1
		if (APlayerData[playerid][PlayerLevel] >= 1) 
		{
		    // Check if the player is inside a vehicle
			if(!IsPlayerInAnyVehicle(playerid))
				return SendClientMessage(playerid, 0xFF0000FF, "You are not in a vehicle!"); // Let the player know he's not inside a vehicle and let the server know that this was a valid command
			// Fully repair the vehicle (damage value and bodywork)
			RepairVehicle(GetPlayerVehicleID(playerid));
			// Send the player a message to inform him that his vehicle has been repaired
			SendClientMessage(playerid, 0x00FF00FF, "Your vehicle has been successfully repaired!");
		}
		else
		    return 0;
	}
	else
	    return 0;

	// Let the server know that this was a valid command
	return 1;
}
How can I change it that only RCON can use it
Reply


Messages In This Thread
RCON only - by rpx - 01.03.2012, 13:39
Re: RCON only - by FalconX - 01.03.2012, 13:46
Re: RCON only - by rpx - 01.03.2012, 13:53
Re: RCON only - by Ballu Miaa - 01.03.2012, 13:54
Re: RCON only - by Vasu99 - 01.03.2012, 13:57
Re: RCON only - by FalconX - 01.03.2012, 13:57
Re: RCON only - by rpx - 01.03.2012, 14:04
Re: RCON only - by FalconX - 01.03.2012, 14:06
Re: RCON only - by Vasu99 - 01.03.2012, 14:21
Re: RCON only - by FalconX - 01.03.2012, 14:40

Forum Jump:


Users browsing this thread: 1 Guest(s)