Textdraw Updating crash?
#2

You can't just throw in playerid and expect it to loop through every player online.

pawn Код:
public statspawn()
{
  new Float:pHealth, string[128], Float:pArmour;;
  for(new playerid; playerid < MAX_PLAYERS; playerid++)
  {
    GetPlayerHealth(playerid, pHealth);
    format(string, sizeof(string), "Health %.0f", pHealth);
    TextDrawSetString(Textdraw0, string);

    GetPlayerArmour(playerid, pArmour);
    format(string, sizeof(string), "Armour %.0f", pArmour);
    TextDrawSetString(Textdraw1, string);

    format(string, sizeof(string), "Cash %d", GetPlayerMoney(playerid));
    TextDrawSetString(Textdraw2, string);

    format(string, sizeof(string), "Ammo %d", GetPlayerAmmo(playerid));
    TextDrawSetString(Textdraw3, string);

    format(string, sizeof(string), "kills %d", GetPlayerScore(playerid));
    TextDrawSetString(Textdraw5, string);
  }
  return 1;
}
Reply


Messages In This Thread
Textdraw Updating crash? - by -Rebel Son- - 29.04.2010, 02:11
Re: Textdraw Updating crash? - by Pixels^ - 29.04.2010, 04:17
Re: Textdraw Updating crash? - by -Rebel Son- - 29.04.2010, 04:21
Re: Textdraw Updating crash? - by -Rebel Son- - 29.04.2010, 04:32

Forum Jump:


Users browsing this thread: 1 Guest(s)