- Documentation
- Shared functions
- setPlayerWaypoint
Function
setPlayerWaypoint
Sets the game's GPS waypoint for a player: a target on the radar and map, and a road route while in a vehicle. The game confirms it with onPlayerWaypointSet.
Syntax
Server
bool setPlayerWaypoint(player thePlayer, float x, float y)Client
bool setPlayerWaypoint(float x, float y)Arguments
thePlayerplayer- The player (server only).
xfloat- Target X position.
yfloat- Target Y position.
Returns
true if the request was sent.
Example
addCommandHandler("dojazd", function(player)
setPlayerWaypoint(player, 1481.0, -1771.0)
outputChatBox("Cel ustawiony: ratusz.", player)
end)