if(strcmp(cmd, "/setwanted", true) == 0)
{
if(GetPlayerLevel(playerid) < 4) return SendClientMessage(playerid,COLOR_RED,"SERVER: Vos no sos sub-administrador para usar ese comando!");
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_YELLOW, "INFO: /setwanted [playerid] [nivel]");return 1;
}
new wanted;
if(IsStringAName(tmp))
{
playerid = GetPlayerID(tmp);
}
else
{
playerid = strval(tmp);
}
tmp = strtok(cmdtext, idx);
wanted = strval(tmp);
GetPlayerName(playerid, NomePlayer, sizeof(NomePlayer));
pName(playerid);
SetPlayerWantedLevel(playerid, wanted);
format(string,sizeof(string),"(%d/%d/%d)[%d:%d:%d] [INFO-ADMIN] El Admin %s cambiу el nivel de procurado del %s.",ano,mes,dia,hora,minuto,segundo,NomePlayer, ppname);
SendMessageToAdmins(COLOR_IADMIN, string);
LogPlayer(playerid, string);
return 1;
}
new bool:PMAtivada[MAX_PLAYERS];
PMAtivada[playerid] = false;
if(strcmp(cmd, "/ativarmp", true) == 0)
{
if(MPAtivada[playerid] == false)
{
MPAtivada[playerid] = true;
SendClientMessage(playerid,-1,"Vocк ativou a leitura de MP's");
}
else
{
MPAtivada[playerid] = false;
SendClientMessage(playerid,-1,"Vocк desativou a leitura de MP's");
}
return 1;
}
public SendMessageToAdmins(color,const string[])
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) == 1)
{
if (GetPlayerLevel(i) >= 4)
{
SendClientMessage(i, color, string);
}
}
}
return 1;
}
public SendMessageToAdmins(color,const string[])
{
for(new i = 0; i < MAX_PLAYERS; i++)
if(IsPlayerConnected(i) == 1)
if (GetPlayerLevel(i) >= 4 && MPAtivada[i] == true)
SendClientMessage(i, color, string);
return 1;
}
C:\Users\Home-R\Desktop\ZonaDeRiesgo[0.3c(R5)]\filterscripts\admin.pwn(17 : error 017: undefined symbol "MPAtivada" C:\Users\Home-R\Desktop\ZonaDeRiesgo[0.3c(R5)]\filterscripts\admin.pwn(17 : warning 215: expression has no effect C:\Users\Home-R\Desktop\ZonaDeRiesgo[0.3c(R5)]\filterscripts\admin.pwn(17 : error 001: expected token: ";", but found "]" C:\Users\Home-R\Desktop\ZonaDeRiesgo[0.3c(R5)]\filterscripts\admin.pwn(17 : error 029: invalid expression, assumed zero C:\Users\Home-R\Desktop\ZonaDeRiesgo[0.3c(R5)]\filterscripts\admin.pwn(17 : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors. |
new bool:MPAtivada[MAX_PLAYERS];