Én így oldottam meg:
#include <a_samp>
#include <dini>
#include <dudb>
#include <colors>
#define FILTERSCRIPT
#pragma unused strtok
public OnFilterScriptInit()
{
print(\"\\n--------------------------------------\");
print(\" Skin mentõ betöltve\");
print(\"--------------------------------------\\n\");
return 1;
}
public OnFilterScriptExit()
{
print(\"\\n--------------------------------------\");
print(\" Skin mentõ kivéve\");
print(\"--------------------------------------\\n\");
return 1;
}
public OnPlayerDisconnect(playerid, reason)
{
new jatekosnev[MAX_PLAYER_NAME], fajl[128];
GetPlayerName(playerid, jatekosnev, sizeof(jatekosnev));
format(fajl,sizeof(fajl),\"ruha/%s.ini\",jatekosnev);
if(!fexist(fajl))
{
GetPlayerName(playerid, jatekosnev, sizeof(jatekosnev));
dini_Create(fajl);
dini_IntSet(fajl,\"Ruha\",GetPlayerSkin(playerid));
}else{
SetPlayerSkin(playerid, dini_Int(fajl, \"Ruha\"));
}
return 1;
}
public OnPlayerSpawn(playerid)
{
new jatekosnev[MAX_PLAYER_NAME], fajl[128];
GetPlayerName(playerid, jatekosnev, sizeof(jatekosnev));
format(fajl,sizeof(fajl),\"ruha/%s.ini\",jatekosnev);
if(fexist(fajl))
{
SetPlayerSkin(playerid, dini_Int(fajl, \"Ruha\"));
}
return 1;
}