PlayerCreateWaypoint: Difference between revisions
m (category) |
(Fixes params) |
||
| Line 1: | Line 1: | ||
Event triggered when a player creates a waypoint | Event triggered when a player creates a waypoint in the map. | ||
==Parameters== | ==Parameters== | ||
* '''position''': Vector3 position of the waypoint | |||
* '''position''' | |||
==Example== | ==Example== | ||
<syntaxhighlight lang="javascript"> | <syntaxhighlight lang="javascript"> | ||
mp.events.add("playerCreateWaypoint", ( | mp.events.add("playerCreateWaypoint", (position) => { | ||
mp.console.logInfo(`New waypoint created at: ${position.x}, ${position.y}, ${position.z}`); | |||
}); | }); | ||
</syntaxhighlight> | </syntaxhighlight> | ||
| Line 16: | Line 14: | ||
[[Category:Waypoint]] | [[Category:Waypoint]] | ||
[[Category:Client-side Event]] | [[Category:Client-side Event]] | ||
Revision as of 22:35, 24 February 2020
Event triggered when a player creates a waypoint in the map.
Parameters
- position: Vector3 position of the waypoint
Example
mp.events.add("playerCreateWaypoint", (position) => {
mp.console.logInfo(`New waypoint created at: ${position.x}, ${position.y}, ${position.z}`);
});