StartPlayerTeleport — FiveM Natives
0xAD15F075A4DA0FDE · PLAYER · all
Teleports the player to the given coordinates. If findCollisionLand is true it will try to find the Z value for you, this however has a timeout of 100 frames. When trying to find the Z value the native will take longer the higher the difference from the given Z to the ground, this combined with the timeout can cause the teleport to just teleport to the given Z value, so try to estimate the z value, so don't just pass in 1000.0. Also if you're in a vehicle and teleportWithVehicle is true it will not find the Z value for you.
Parameters
| Name | Type | Description |
|---|---|---|
| player | Player | |
| x | float | |
| y | float | |
| z | float | |
| heading | float | |
| teleportWithVehicle | BOOL | Teleports the player along with the vehicle they are in. |
| findCollisionLand | BOOL | Attempt to find a ground coordinate at the given XY location; overriding the Z value. |
| p7 | BOOL |
Returns
void