SA-MP Forums Archive
Problem with cash&skin - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Problem with cash&skin (/showthread.php?tid=401251)



Problem with cash&skin - trolltomax - 22.12.2012

Hello.. i have problem,when register i do not get money and skin,on script is set 500$ and skin ID 23..



here is set,

Код:
new INI:File = INI_Open(UserPath(playerid));
                INI_SetTag(File,"data");
                INI_WriteInt(File,"Password",udb_hash(inputtext));
                INI_WriteInt(File,"Cash",500);
                INI_WriteInt(File,"Admin",0);
                INI_WriteInt(File,"Kills",0);
                INI_WriteInt(File,"Deaths",0);
				INI_WriteInt(File,"Skin", 23);
                INI_Close(File);



Re: Problem with cash&skin - park4bmx - 22.12.2012

is not set you saved it into a file but never give the money/skin to the player !
use before the new INI:File = INI_Open(UserPath(playerid));
GivePlayerMoney(playerid,500); and for the skin SetPlayerSkin(playerid,23);


Re: Problem with cash&skin - trolltomax - 22.12.2012

ohhh. thanks a lot. :beer:


but skin dont work..
maybe problem is


Код:
SetSpawnInfo(playerid, 0, 0, 1216.7485,-1814.3013,16.5938,270.7115, 0, 0, 0, 0, 0, 0);



Re: Problem with cash&skin - park4bmx - 22.12.2012

pawn Код:
SetSpawnInfo(playerid, 0, 23, 1216.7485,-1814.3013,16.5938,270.7115, 0, 0, 0, 0, 0, 0);
There u go if u had that then it would forced the skin to be "0" but now it would be "23"
Quote:

This forum requires that you wait 120 seconds between posts.

And again ;X


Re: Problem with cash&skin - trolltomax - 22.12.2012

again CJ skin.


Re: Problem with cash&skin - park4bmx - 22.12.2012

Then your settings the players skin to something else.
OnPlayerRequestSpawn/OnPlayerRequestClass/OnPlayerSpawn or something, check.


Re: Problem with cash&skin - Konstantinos - 22.12.2012

In OnPlayerSpawn, set the skinid.


Re: Problem with cash&skin - trolltomax - 23.12.2012

Код:
public OnPlayerSpawn(playerid)
{
    SetOriginalColor(playerid);
	SetPlayerSkin(playerid, PlayerInfo[playerid][pSkin]);
	return 1;
}
i have