07.06.2015, 03:33
Good evening, I'm kind of sad and angry, today I was all day in just a fucking [B] InterpolateCamera [/ B], is as follows, I have these following coordinates ..
and above this function:
My problem is that when a person logs on the server, it is close to the above coordinates, for example, the camera walked and when the player gives the spawn, it is in that position, the last place where the camera InterpolateCameraPos stood, instead the player go to normal spawn, which is his HQ organization, he is flying in the sky and then immediately falls and dies .. of course .. do not know the solution, researched, tried (WIKI ) and I found, did everything, even plagiarism of coordinated I try, nothing else would I want to solve this soon, but with your help urgently, to me is already complex.
I will show just enough of my public OnPlayerLogin
Why the public? By then immediately after the dialogue, is where the player takes the first spawn after login, do not know where you put it, because this TogglePlayerSpectating angered me today, this bug once (0.3C) many people had (I think), we see if the board're helping you need right ..
In OnPlayerSpawn has only coordinates where the player will take the spawn, ie in its HQ ..
PHP код:
InterpolateCameraPos(playerid, 2365.8767, -1485.5969,75.7918, 2132.2759, -941.1163,109.6049 10000);
InterpolateCameraLookAt(playerid, 2132.8271, -974.1696,108.3467, 1720.5673, -1203.7601,113.5448 10000);
PHP код:
TogglePlayerSpectating (playerid, true);
PHP код:
public OnPlayerRequestClass (playerid, classid)
{
TogglePlayerSpectating (playerid, true);
InterpolateCameraPos (playerid, 2365.8767, -1485.5969,75.7918, 2132.2759, -941.1163,109.6049 10000);
InterpolateCameraLookAt (playerid, 2132.8271, -974.1696,108.3467, 1720.5673, -1203.7601,113.5448 10000);
// Just below, shows the dialogue login and registration (I think not need to show)
// I've tried to put the above code in OnplayerConect, plus the screen lock all ..
}
I will show just enough of my public OnPlayerLogin
PHP код:
public OnPlayerLogin(playerid, password [])
{
TogglePlayerSpectating (playerid, false);
SetSpawnInfo(playerid, 0, PlayerInfo [playerid] [pchar], 1447.7323, -1663.1010, 13.5530, 1.0, -1, -1, -1, -1, -1, -1);
SpawnPlayer(playerid);
}
In OnPlayerSpawn has only coordinates where the player will take the spawn, ie in its HQ ..