Bug: Ambient movement erratic when a new path is specified

From Dragon Age Toolset Wiki
Revision as of 08:24, 18 May 2011 by Proleric1 (Talk | contribs) (Created page with '*'''Toolset verion:''' 1.0.1008.0 *'''Game version:''' 1.04 *'''Status:''' Open == Description == <!-- Describe the bug here including as many details as possible. What situati...')

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
  • Toolset verion: 1.0.1008.0
  • Game version: 1.04
  • Status: Open

Description

The Ambient_Start function allows the waypoint path AMBIENT_MOVE_PREFIX to be specified.

However, if it is used to specify a new path for a creature, the new waypoints may be visited in the wrong order.

Specifically, if the creature last moved to old path waypoint N, it will visit new path waypoint N before new path waypoint 1.

This has been verified in AMBIENT_MOVE_ONCE mode, but probably affects most movement patterns.

Ambient_StartTeam() and Ambient_StartTag() depend on Ambient_Start, so they have the same bug.

Workarounds

Add the following initialistions before calling Ambient_Start:

SetLocalInt(oCreature, AMBIENT_MOVE_COUNT, AMBIENT_MOVE_COUNT_INVALID); 
SetLocalInt(oCreature, AMBIENT_MOVE_STATE,  AMBIENT_MOVE_NEXT);              
Ambient_Start(oCreature, ...

where oCreature is the creature object in question.