Little Help
#1

level 10 Can Use This Feature ,How To Make it for only rcon admin ? ?

Код:
			case 4:{
				if (PlayerInfo[playerid][Level] >= 10 && PlayerInfo[playerid][LoggedIn] == 1) {
					aresetcar(playerid);
					SendClientMessageToAll(COLOR_ORANGE, "Vehicle Has Been Reset.");
				}
				else{	SendClientMessage(playerid, COLOR_BRIGHTRED, "You are not a level 10 admin and cannot use this feature!"); }
				HideMenuForPlayer(Current, playerid);
				TogglePlayerControllable(playerid, true);
			}
			case 5:{
				if (PlayerInfo[playerid][Level] >= 10 && PlayerInfo[playerid][LoggedIn] == 1) {
					aresetallcar();
					fremove(V_FILE_SAVE);
					LoadVehicles();
					SendClientMessageToAll(COLOR_ORANGE, "All Vehicles Have Been Reset.");
				}
				else{	SendClientMessage(playerid, COLOR_BRIGHTRED, "You are not a level 10 admin and cannot use this feature!"); }
				HideMenuForPlayer(Current, playerid);
				TogglePlayerControllable(playerid, true);
			}
Reply
#2

if you want only rcon admins
pawn Код:
if(IsPlayerAdmin(playerid))
{
//code
}
if both admins and rcon admin
pawn Код:
if(IsPlayerAdmin(playerid) || PlayerInfo[playerid][Level] >= 1)
{
//code
}
Reply
#3

@emokidx111 Ty +REP
Reply
#4

it goes to ''if(IsPlayerAdmin(playerid))''
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)