SetPlayerCameraPos
From SA-MP Wiki
Description:
Sets the camera to a specific position for a player.
(playerid, Float:x, Float:y, Float:z)
playerid | ID of the player |
Float:x | The X coordinate to place the camera at. |
Float:y | The Y coordinate to place the camera at. |
Float:z | The Z coordinate to place the camera at. |
Return Values:
- 1: The function executed successfully.
- 0: The function failed to execute. The player specified doesn't exist.
Example Usage:
SetPlayerCameraPos(playerid, 652.23, 457.21, 10.84);
Important | Using the camera functions directly after enabling spectator mode doesn't work. |
Notes |
|
Related Functions
The following functions may be useful, as they are related to this function in one way or another.
- SetPlayerCameraLookAt: Set where a player's camera should face.
- SetCameraBehindPlayer: Set a player's camera behind them.