new Float:X, Float:Y, Float:Z, Float:A, IntID, World;
GetPlayerPos(playerid, X, Y, Z);
GetPlayerFacingAngle(playerid, A);
IntID = GetPlayerInterior(playerid);
World = GetPlayerVirtualWorld(playerid);
format(Msg, sizeof(Msg), "You Have Set A New Spawn Location. ** X: (%0.2f) Y: (%0.2f) Z: (%0.2f) Angle: (%.2f) Interior: (%d) World: (%d)**",X, Y, Z, A, IntID, World);
SendClientMessage(playerid, COLOR_LIGHTBLUE, Msg);
dUserSetFLOAT ( PlayerName2( playerid ) ).( "SpawnX", floatround( X ) );
dUserSetFLOAT ( PlayerName2( playerid ) ).( "SpawnY", floatround( Y ) );
dUserSetFLOAT ( PlayerName2( playerid ) ).( "SpawnZ", floatround( Z ) );
dUserSetFLOAT ( PlayerName2( playerid ) ).( "SpawnAngle", floatround( A ) );
dUserSetINT ( PlayerName2( playerid ) ).( "SpawnInterior", IntID );
dUserSetINT ( PlayerName2( playerid ) ).( "SpawnWorld", World );
SetPlayerPos (playerid, dUserINT(PlayerName2(playerid)).("SpawnX"), dUserINT(PlayerName2(playerid)).("SpawnY"), dUserINT(PlayerName2(playerid)).("SpawnZ"));
SetPlayerInterior (playerid, dUserINT(PlayerName2(playerid)).("SpawnInterior"));
SetPlayerVirtualWorld (playerid, dUserINT(PlayerName2(playerid)).("SpawnWorld"));
SetPlayerFacingAngle (playerid, dUserINT(PlayerName2(playerid)).("SpawnAngle"));
SetPlayerPos (playerid, dUserINT(PlayerName2(playerid)).("SpawnX"), dUserINT(PlayerName2(playerid)).("SpawnY"), dUserINT(PlayerName2(playerid)).("SpawnZ"));
SetPlayerFacingAngle (playerid, dUserINT(PlayerName2(playerid)).("SpawnAngle"));
SetPlayerPos (playerid, dUserFloat(PlayerName2(playerid)).("SpawnX"), dUserFloat(PlayerName2(playerid)).("SpawnY"), dUserFloat(PlayerName2(playerid)).("SpawnZ"));
SetPlayerFacingAngle (playerid, dUserFloat(PlayerName2(playerid)).("SpawnAngle"));
dUserSetFLOAT ( PlayerName2( playerid ) ).( "SpawnX", X );
dUserSetFLOAT ( PlayerName2( playerid ) ).( "SpawnY", Y );
dUserSetFLOAT ( PlayerName2( playerid ) ).( "SpawnZ", Z );
dUserSetFLOAT ( PlayerName2( playerid ) ).( "SpawnAngle", A );
lol, it worked fine with INT, and ye i didn't noticed that D: and btw, dUserFLOAT*
btw, still doesn't work. :/ When i save, it does print the correct interior id, but won't load it ;o |
[19:48:56] You Have Set A New Spawn Location. ** X: (-1460.41) Y: (1589.93) Z: (1052.75) Angle: (356.01) Interior: (14) World: (0)** [19:49:05] Spawned, X: -1460.000000, Y: 1590.000000, Z: 1053.000000, Angle: 0.000000, Interior: 0, World: 1135738880