SA-MP Forums Archive
Why doesn't this work? - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Why doesn't this work? (/showthread.php?tid=146255)



Why doesn't this work? - Jochemd - 06.05.2010

Hello,

pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
  GetPlayerCameraPos(playerid, x, y, z);
  SetPlayerCameraPos(playerid, x, y, z);
    }
new Float:x, Float:y, Float:z;  GetPlayerCameraPos(playerid, x, y, z);
  SetPlayerCameraPos(playerid, x, y, z);
That is used in OnPlayerDeath
I want it so it SETS your camera THERE, even if you spawn, your camera just stays being the place that SetPlayerCameraPos sets it. But why doesn't it work?


Re: Why doesn't this work? - dice7 - 06.05.2010

Get the positions under OnPlayerDeath and set the camera under OnPlayerSpawn