Editors Depot

[ArmA] findNearestWaypoint by Wolfrug

Version 1
Added 11 Aug 2009
Downloads 210
Demo included Yes
Filesize 4.7KB
User rating Not yet rated

A function for determining the closest waypoint to any particular map spot.

findNearestWaypoint.sqf function:

Input 2d position (from onMapSingleClick or waypointPosition for instance).
Input name of trigger that covers wider area you want checked/is activated by side you want checked (or Anybody if you don't care).
(Optionally input minimum distance the waypoint has to be from the 2d position for it to return anything)

Output : waypoint (in waypoint format, i.e. [GroupName, WaypointNumber]) closest to position input.

View the forum thread for this resource here.

Click to see 4 other resources by this author.

Search OFPEC Editors Depot


The OFPEC Command Reference contains details of all scripting commands available to the editor.

Beginner's Tutorial

All you need to know about how to start editing.

Multiplayer Tutorial

This tutorial explains the mysteries of multiplayer editing.

OFPEC Tutorials

OFPEC hosts several quality tutorials written specifically for the site by staff and members...


Register a tag, browse for addon keys...