Skip to content

48 — Center Camera at Waypoint...

Pans the tactical view to a waypoint over a fixed number of frames rather than jumping to it.

Editor data
Numeric ID
48
Engine ID
TACTION_CENTER_VIEWPOINT
Editor name
Center Camera at Waypoint...
Need token
NEED_SPEED_AND_LOCATION
Parameters
  1. Speedcamera-speed
  2. Waypointwaypoint
Attachment
none
INI example
[Actions]
<TriggerID>=1,48,0,<Speed>,0,0,0,0,<Waypoint>

The destination is the waypoint’s cell at its ground height, raised by the bridge height where a bridge covers or has covered that cell. The view’s position at the moment the action runs becomes the starting point, and a progress figure starts at zero.

Each frame afterward the speed’s rate is added to that progress figure and the view is placed that fraction of the way from the starting point to the destination. The pan ends on the frame the figure reaches one. The motion is linear from end to end, with no easing, and the whole journey is divided the same way whatever its length — which is why the five rates are described in frames to arrive rather than in speed.

Valid values

  • One of the five camera speeds and a scenario waypoint.
Caveats
  • The speed is handed to the pan as a position in a table of five rates with no range check. The team script mission that centers the view on a team passes its own figure through the same routine, so both are affected alike.
  • The speed fixes how long the pan takes, not how fast it travels, so a hop of two cells and a run across the map occupy the same number of frames.
  • The action does not lock input. A player scrolling during the pan is overridden every frame until it arrives.
  • A second pan asked for before the first has arrived replaces it and starts afresh from wherever the view has reached.