17.12.2014, 21:05
Okay so here is the problem
I have a stock for adding money but the problem is that it doesnt add the money but sets it to the value assigned
So here is my stock
I have a stock for adding money but the problem is that it doesnt add the money but sets it to the value assigned
So here is my stock
Код:
stock ACLA_GivePlayerMoney(playerid, iznos)
{
if(iznos > 0)
{
PlayerInfo[playerid][pNovcanik] += iznos;
GivePlayerMoney(playerid, iznos);
new kolikopara[40];
format(kolikopara,sizeof(kolikopara),"~g~+%d$",iznos);
TextDrawSetString(MinusiPlus[playerid], kolikopara);
TextDrawShowForPlayer(playerid, MinusiPlus[playerid]);
}
else
{
new konacaniznos = iznos * -1;
PlayerInfo[playerid][pNovcanik] -= konacaniznos;
GivePlayerMoney(playerid, -konacaniznos);
new kolikopara[40];
format(kolikopara,sizeof(kolikopara),"~r~%d$",iznos);
TextDrawSetString(MinusiPlus[playerid], kolikopara);
TextDrawShowForPlayer(playerid, MinusiPlus[playerid]);
}
SetTimerEx("NestaniNetacni", 3000, false, "ii", playerid,2);
}

