Components
ObjectTransportAction
Move or rotate a subject immediately, through an NPC route adapter, or through a project-owned path adapter.
Move through a bounded integration action
ObjectTransportAction is a serializable action used by Ordered Objective start/completion lists and by Detonator. It supports immediate transform changes plus adapter-based path or NPC routing. The Core never references a specific pathfinding or AI package.
Use Teleport or RotationOnly for deterministic immediate changes. Use PathMovement or NpcRoute only after the project supplies the corresponding public adapter. This action starts movement; the adapter remains responsible for duration, cancellation, collision, animation, and arrival behavior.
Modes and conditional fields
| Mode | Required fields | Result |
|---|---|---|
| Teleport | Subject, Destination | Copies position and rotation immediately |
| RotationOnly | Subject, Destination | Copies rotation only |
| PathMovement | Subject, Path Source; IPathMovementAdapter on Subject | Calls StartMovement(subject, pathSource) |
| NpcRoute | NPC Adapter implementing INpcRouteAdapter, Path Source | Calls StartRoute with nearby-player flag, optional current ID, and clamped speed |
Developer Title labels the action for authors. Complete Current Objective does not complete Core directly; in NpcRoute mode it passes the current Objective ID to the external adapter so that integration may complete it when its route truly ends.
Execution contract and warnings
Execute(Chapter chapter = null) dispatches exactly one mode. Missing Subject or Destination in transform modes logs a warning. PathMovement searches MonoBehaviours on the Subject for the first IPathMovementAdapter; missing Subject, Path Source, or adapter warns. NpcRoute requires the assigned MonoBehaviour to implement INpcRouteAdapter and also requires a Path Source.
Invalid references do not advance or roll back the Ordered Objective automatically. If transport is essential to the task, Validation and a Play Mode acceptance test must prove the adapter call reaches the project system.
Example and reset responsibility
- 1Add a start transport action to an Ordered Objective and choose Teleport.
- 2Assign the NPC root as Subject and a scene marker as Destination.
- 3Select Play in Unity's top toolbar. When start work runs, position and rotation must match the marker before On Objective Start listeners execute.
- 4For animated movement, implement
IPathMovementAdapteron the Subject, switch to PathMovement, and assign a project path component as Path Source.
The action has no Reset method and does not remember previous transforms. Add explicit return movement or scene restoration to the project when a Chapter can restart or step back. See Movement and Route Adapters for compiled integration code.