30.06.2013, 02:03
Se nгo conseguir resolver agora, desiste. rs!
pawn Код:
new Text:Patentes[MAX_PLAYERS]; // Textdraw Global
public OnGameModeInit()
{
for(new i; i<MAX_PLAYERS; i++)
{
Patentes[i] = TextDrawCreate...
}
return true;
}
stock GetarRank(playerid)
{
switch (PlayerDados[playerid][Level])
{
case 0: NomeRank = "Novato";
case 1: NomeRank = "Recruta";
case 2: NomeRank = "Soldado";
case 3: NomeRank = "Cabo";
case 4: NomeRank = "Sargento";
}
return true;
}
forward Atualizar();
public Atualizar()
{
new string[50];
for(new i; i<MAX_PLAYERS; i++) if(IsPlayerConnected(i))
{
format(string, 50, "~g~~h~ ~>~Ranking~<~~n~~h~ %s", GetarRank(i));
TextDrawSetString(Patentes[i], string), TextDrawShowForPlayer(i, Patentes[i]);
}
return true;
}

