14.12.2016, 18:19
Hellou.
I'm making a datapack system. It's like moneybag system, when you pick it up you will get cash ( or score ).
But when i pick it up i got ivalid valute showen.
Problem is when i pickup a data that first format is showing me that I have 0 packs, but after picking up another one i got 1 instead of 2.
Command datastatus is showing correct, can anyone explain me?
IMG(s).http://forum.sa-mp.com/newthread.php?do=postthread&f=12
I'm making a datapack system. It's like moneybag system, when you pick it up you will get cash ( or score ).
But when i pick it up i got ivalid valute showen.
Код:
CMD:pickupdata(playerid, params[]) { if (IsPlayerInRangeOfPoint(playerid, 7.0, 2001.5299,1520.2451,17.0625)) { SendClientMessage(playerid, -1, " You have picked up a datapack! Collecting more wil lead into a reward! "); new string[128]; format(string,sizeof(string), " You have collected one datapack and now you have %d packs.", datapack); SendClientMessage(playerid, -1, string); GivePlayerMoney(playerid, -1, 10000); datapack[playerid] = 1; } else { SendClientMessage(playerid, -1, " You're not near datapack"); } return 1; } CMD:datastatus(playerid, params[]) { new string[128]; format(string,sizeof(string), " You have just %d packs!", datapack); SendClientMessage(playerid, -1, string); return 1; }
Command datastatus is showing correct, can anyone explain me?
IMG(s).http://forum.sa-mp.com/newthread.php?do=postthread&f=12