Uživajte 🙂
//-- Money sistem NA POCETAK SKRIPTE
new Text:pare0;
forward Cosak(playerid);
new CosakTimer;
ONPLAYERCONNECT
CosakTimer=SetTimerEx("Cosak", 800,1,"i", playerid);
//--Pare sistem--
pare0 = TextDrawCreate(497.000000, 97.000000, "$0000000");
TextDrawBackgroundColor(pare0, 255);
TextDrawFont(pare0, 3);
TextDrawLetterSize(pare0, 0.700000, 2.200000);
TextDrawColor(pare0, -32568);
TextDrawSetOutline(pare0, 1);
TextDrawSetProportional(pare0, 1);
NA DNO MODA
public Cosak(playerid)
{
new pare = GetPlayerMoney(playerid);
new acc = PlayerInfo;
new string;
if(acc > 0)
{
format(string, sizeof(string), "$%d", acc);
TextDrawSetString(pare0, string);
TextDrawShowForPlayer(playerid, pare0);
}
else if(acc < 0)
{
format(string, sizeof(string), "~r~-$%d", acc);
TextDrawSetString(pare0, string);
TextDrawShowForPlayer(playerid, pare0);
}
else if(acc == 0)
{
format(string, sizeof(string), "$0");
TextDrawSetString(pare0, string);
TextDrawShowForPlayer(playerid, pare0);
}
return 1;
}
ONPLAYERDISCONNECT
KillTimer(CosakTimer);http://pastebin.com/z3Q0L1JM
EDIT: Zaboravio sam sliku, izvinite.
