08.04.2011, 00:42
Galera й assim quando dou /procurar 5 5 envez de dar 5 estrelas pro id 5 dar 5 estrelas pro id 0 '-' como faзo agora ? ajudem porfavor
Aguardando Resposta...
PHP код:
if(strcmp(cmd, "/procurar", true) == 0 || strcmp(cmd, "/wanted", true) == 0)
{
GetPlayerName(playerid, sendername, sizeof(sendername));
PlayerInfo[playerid][pBOPE] = dini_Int(udb_encode(sendername), "levelbope");
new wlevel, leveladd[256];
tmp = strtok(cmdtext, idx);
leveladd = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GREEN, "Uso correto: /wanted(level) [id do player] [level (0-6)]");
}
giveplayerid = strval(tmp);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GREEN, "Uso correto: /wanted(level) [id do palyer] [level (0-6)]");
}
wlevel = strval(tmp);
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
if(logged[playerid] == 1)
{
if(PlayerInfo[playerid][pBOPE] >= 1 || PlayerInfo[playerid][pGOE] >= 1 || PlayerInfo[playerid][pPM] >= 1 || PlayerInfo[playerid][pEXC] >= 1)
{
if(IsPlayerConnected(giveplayerid))
{
if(wlevel >=0 || wlevel <=6)
{
SendClientMessage(playerid, COLOR_GREEN, "Wanted level syntax: 0 - 6");
}
format(string, sizeof(string), "* ADMIN:: Vocк mudou o level de procurado de %s(%i) para %d.", giveplayer, giveplayerid, wlevel);
SendClientMessage(playerid, COLOR_ADM, string);
format(tmp, sizeof(tmp), "* ADMIN: %s(%i) mudou seu level de procurado para %d.", sendername, playerid, wlevel);
SendClientMessage(giveplayerid, COLOR_ADM, string);
SetPlayerWantedLevel(giveplayerid, wlevel);
}
else
{
format(string, sizeof(string), "%d nгo й um player ativo!", giveplayerid);
SendClientMessage(playerid, COLOR_CYAN, string);
}
}
else
{
SendClientMessage(playerid, COLOR_CYAN, "Vocк nгo tem permissгo para usar este comando!");
}
}
else
{
SendClientMessage(playerid, COLOR_CYAN, "Vocк tem que estar logado para usar este comando!");
}
return 1;
}