15.02.2013, 23:36
So, I used a Dini code to save my position, and I made the folder and everything like that. But it would spawn you in blueberry, it worked. But it would spawn you there.
I added:
and it puts you at Cranberry station, but doesn't save your position
I used this dini code
I need some help lol :P
Will REP + for the answer
I added:
Код:
SetPlayerPos(playerid, -1980.5990,138.0181,27.6875);
I used this dini code
Код:
public OnPlayerDisconnect(playerid, reason)
{
new file[128], pname[MAX_PLAYER_NAME];
new Float:x, Float:y, Float:z;
GetPlayerName(playerid, pname, sizeof(pname));
format(file, sizeof(file), "\\SavePos\\%s.ini", pname);
if(!dini_Exists(file))
dini_Create(file);
GetPlayerPos(playerid, x, y, z);
dini_FloatSet(file, "posX", x);
dini_FloatSet(file, "posY", y);
dini_FloatSet(file, "posZ", z);
return 1;
}
public OnPlayerSpawn(playerid)
{
new file[128], pname[MAX_PLAYER_NAME];
new Float:x, Float:y, Float:z;
GetPlayerName(playerid, pname, sizeof(pname));
format(file, sizeof(file), "\\SavePos\\%s.ini", pname);
x = dini_Float(file, "posX");
y = dini_Float(file, "posY");
z = dini_Float(file, "posZ");
SetPlayerPos(playerid, x, y, z);
SetPlayerColor(playerid, 0xFFFFFFFF );
SetPlayerPos(playerid, -1980.5990,138.0181,27.6875);
return 1;
}
Will REP + for the answer


