Skip to content

NavGridAgent Set Direction

Sets the intended movement direction on a NavGridAgent.

Default update mode: Update Every Frame.

Parameter Description
NavGrid Agent Agent to control.
Direction Desired input direction (for example from axis input).
Movement Optional output resulting movement vector constrained by the grid.
Is Moving Optional output true while the agent is moving.

Notes

  • This action sets intent; actual movement is still constrained by NavGrid walkability and neighbor rules.

Example

  1. Feed input vector into Direction each frame.
  2. Use Is Moving to switch animation state.

See also