---
name: "addWaypoint"
type: command
status: ok
groups: ["Waypoints"]
arma3_since: "0.50"
locality: {"argument": "global", "effect": "global", "server_exec": false}
source: https://community.bistudio.com/wiki/addWaypoint
revid: 377574
updated: 2026-01-02T06:56:28Z
---

# addWaypoint

*Command · Waypoints · Arma 3 v0.50 · introduced in Operation Flashpoint: Elite v1.00*

Locality: arguments **global** · effect **global**

## Description

Adds (or inserts when index is given) a new waypoint to a group.

The waypoint is placed randomly within a circle with the given center and radius.

> [!NOTE]
> For older titles and prior to Arma 3 v1.90, use [setWaypointPosition](../commands/setWaypointPosition.md) if you need exact waypoint placement.

## Syntax

```sqf
groupName addWaypoint [center, radius, index, name]
```

**Parameters:**

- `groupName`: [Group](../topics/Group.md)
- `center`: [PositionAGL](../topics/Position.md#positionagl) ([PositionASL](../topics/Position.md#positionasl) if *radius* is negative!) or [Object](../topics/Object.md)
- `radius`: [Number](../topics/Number.md) - random waypoint placement within *radius* from *center*; Arma 3 v1.90 -1 can be used for exact waypoint placement
- `index`: [Number](../topics/Number.md) - (Optional, default -1) can be used to insert a waypoint in between existing waypoints; if it is invalid, the waypoint will be added at the end
- `name`: [String](../topics/String.md) - (Optional, default "") [waypointName](../commands/waypointName.md)

**Returns:** Waypoint

## Examples

### Example 1

```sqf
_wp = _grp addWaypoint [position player, 0];
```

### Example 2

```sqf
_wp = _grp addWaypoint [position player, 0];            // imprecise, placed like [[setVehiclePosition]]'s "NONE" placement
_wp setWaypointPosition [getPosASL player, -1];            // from Operation Flashpoint: Elite to Arma 3 v1.88

private _wp = _grp addWaypoint [getPosASL player, -1];    // Arma 3 v1.90+: precise placement
```

## See also

[waypoints](../commands/waypoints.md) · [createGuardedPoint](../commands/createGuardedPoint.md) · [deleteWaypoint](../commands/deleteWaypoint.md) · [copyWaypoints](../commands/copyWaypoints.md) · [move](../commands/move.md) · [setCurrentWaypoint](../commands/setCurrentWaypoint.md) · [setWaypointBehaviour](../commands/setWaypointBehaviour.md) · [setWaypointCombatMode](../commands/setWaypointCombatMode.md) · [setWaypointCompletionRadius](../commands/setWaypointCompletionRadius.md) · [setWaypointDescription](../commands/setWaypointDescription.md) · [setWaypointHousePosition](../commands/setWaypointHousePosition.md) · [setWaypointPosition](../commands/setWaypointPosition.md) · [currentWaypoint](../commands/currentWaypoint.md) · [waypointName](../commands/waypointName.md) · [waypointSpeed](../commands/waypointSpeed.md) · [setWPPos](../commands/setWPPos.md)

## Community notes

**Tijmenjoppe** — 2009-11-26

In game versions prior to Arma 3 v1.22:
If you add a waypoint to your group and then want them to start moving to that waypoint, make sure to call [setWaypointType](../commands/setWaypointType.md) "MOVE" on your waypoint.

---

**Giova** — 2014-06-21

if you want to create a waypoint of type "MOVE" and set it as actual waypoint, you can use the [move](../commands/move.md) command that does everything for you with only one line of code !

Be aware that [move](../commands/move.md) command intercepts multiple waypoints and it will not line up in waypoints queue.
In other word it is a quick solution if you want your group to get only one waypoint, but for several waypoints you'll have to use addwaypoint and all setwaypointXXXXXX commands around.
see [move](../commands/move.md) command.

---

**OdinViking** — 2014-08-05

The waypoint may not be created exactly at the center position even if radius is zero. The position will be moved away if there are e.g. rocks at the center position or if it is placed at the edge of water on a shore.

<sub>Source: [BI Community Wiki — addWaypoint](https://community.bistudio.com/wiki/addWaypoint) (revision 377574).</sub>
