10.11.2015, 00:54
pawn Код:
CMD:check(playerid, params[])
{
if(gLogged[playerid] == 0) SendLanguageMessage(playerid, COLOR_WHITE, LoginOnlyEN, LoginOnlyRO);
else if(PlayerInfo[playerid][pAdmin] < 1 && PlayerInfo[playerid][pHelper] < 1) SendLanguageMessage(playerid, COLOR_WHITE, "{FFFFCC}Error: You are not admin or a helper.", "{FFFFCC}Eroare: Nu esti admin sau helper.");
else if(AccountLocked[playerid] == 0) SendLanguageMessage(playerid, COLOR_WHITE, "{FFB870}Error: Your account is locked. Type /unlockacc to unlock it and use this command.", "{FFB870}Eroare: Contul tau este blocat. Scrie /unlockacc pentru a il debloca si pentru a folosi aceasta comanda.");
else
{
new id;
sscanf(params, "?<CELLMIN_ON_MATCHES=1>U(-1)", id);
if(id == -1)
{
// No player was entered.
SendLanguageMessage(playerid, COLOR_WHITE, "{B8DBFF}Synthax: /check <Name/Playerid>","{B8DBFF}Sintaxa: /check <Nume/ID>");
}
else if(id == cellmin)
{
// Multiple matches found
// Uchiha is found in multiple name please be more specific
SendLanguageMessage(playerid, 0xFFFFFFFF, "{FFFFCC}Player is found in multiple name please be more specific.", "{FFFFCC}Prea multi jucatori corespund cautarii. Foloseste unul dintre aceste ID-uri.");
}
else if(id == INVALID_PLAYER_ID)
{
// Entered player is not connected.
SendLanguageMessage(playerid, COLOR_WHITE, PlayerOfflineEN, PlayerOfflineRO);
}
else
{
// Found just one player.
ShowStats(playerid, id);
}
}
return 1;
}