Format is showing wrong!
#1

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.

Код:
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;
}
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
Reply


Messages In This Thread
Format is showing wrong! - by Fratello - 14.12.2016, 18:19
Re: Format is showing wrong! - by saffierr - 14.12.2016, 18:22
Re: Format is showing wrong! - by Fratello - 14.12.2016, 18:25
Re: Format is showing wrong! - by GoldenLion - 14.12.2016, 19:01
Re: Format is showing wrong! - by Fratello - 14.12.2016, 19:14
Re: Format is showing wrong! - by Konstantinos - 14.12.2016, 19:23
Re: Format is showing wrong! - by Fratello - 14.12.2016, 19:29

Forum Jump:


Users browsing this thread: 1 Guest(s)