SA-MP Forums Archive
save player skin and show it to player when login? - 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: save player skin and show it to player when login? (/showthread.php?tid=313073)



save player skin and show it to player when login? - the.et - 24.01.2012

How can i only show the skin(OnPlayerRequestClass) that player set during first registry? on the gamemodeint , i already added a few AddPlayerClass.


I have set up a mysql system for my server.

OnPlayerConnect and after the login , the script will go to my server and get the player data and store it in variables.

I stored two variables :
new skin[MAX_PLAYERS];
new cskin[MAX_PLAYERS];

skin is skinID and cskin is chose skin(for verifying the player has chosen skin , value :0/1).

How can i only show the skin they selected and unable to click left or right? the skin ID is in skin variable.

I hope someone could guide me.


Re: save player skin and show it to player when login? - the.et - 24.01.2012

anyone?


Re: save player skin and show it to player when login? - MSI - 24.01.2012

pawn Код:
SetPlayerSkin(playerid, skin id)/*Don't change the playerid, only the skin id*/
For more help just pm me

Skin id's https://sampwiki.blast.hk/wiki/Category:Skins


Re: save player skin and show it to player when login? - Guest4390857394857 - 22.02.2014

Quote:
Originally Posted by MSI
Посмотреть сообщение
pawn Код:
SetPlayerSkin(playerid, skin id)/*Don't change the playerid, only the skin id*/
For more help just pm me

Skin id's https://sampwiki.blast.hk/wiki/Category:Skins
what saving system r u using
like dini/dutils/yini/mysql/sqlite ?

give us some more data to reply with a perfect solution!


Re: save player skin and show it to player when login? - FilesMAker - 22.02.2014

you need to load the skin and put it on SetSpawInfo()
Код:
if(cskin[playerid])
SetSpawnInfo(playerid, 0, skin[playerid], X, Y, Z, 0, 0, 0, 0, 0, 0 );
edited to your statment !


Re : save player skin and show it to player when login? - S4t3K - 22.02.2014

I think he want to show the model skin to the player when logging in (like mSelection)

Use mSelection, include made by d0, who allows you to show models in textdraws.
You just have to add models on a list in your scriptfiles folder (like skins.txt).
Then, display the skin with the function (i'm not very good on textdraws at all, so i won't show you an example, because if I do a mistake, you'll maybe learn the mistake)


Re: save player skin and show it to player when login? - Beckett - 22.02.2014

Quote:
Originally Posted by ShivRp
Посмотреть сообщение
what saving system r u using
like dini/dutils/yini/mysql/sqlite ?

give us some more data to reply with a perfect solution!
He said MYSQL already.