Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#1669 closed defect (fixed)

Failing to complete garrison order breaks unit state

Reported by: zoot Owned by: Deiz
Priority: Should Have Milestone: Alpha 12
Component: Core engine Keywords:
Cc: leper Patch:

Description

If a unit fails to complete a queued garrison order (e.g. because the garrison holder is full) and the next order in the queue is a "combat" order (e.g. kill a chicken), the unit will enter a bizarre state throwing errors like this on every order given to the unit thereafter (even after the queue has been executed):

ERROR: Tried to process unhandled event 'Timer' in state 'INDIVIDUAL.GARRISON.GARRISONED'

Change History (4)

comment:1 by zoot, 12 years ago

Summary: Failing to complete garrison order breaks queueFailing to complete garrison order breaks unit state

comment:2 by Deiz, 12 years ago

Owner: set to Deiz
Resolution: fixed
Status: newclosed

In 12674:

Always abort the FSM transition when failing to enter a state. Fixes #1669.

comment:3 by Kieran P, 12 years ago

Milestone: BacklogAlpha 12

comment:4 by zoot, 12 years ago

The fix works, but now I'm getting these warnings when starting a new game:

WARNING: JavaScript warning: simulation/components/UnitAI.js line 1128
anonymous function does not always return a value
WARNING: JavaScript warning: simulation/components/UnitAI.js line 1147
anonymous function does not always return a value
WARNING: JavaScript warning: simulation/components/UnitAI.js line 1535
anonymous function does not always return a value
WARNING: JavaScript warning: simulation/components/UnitAI.js line 1681
anonymous function does not always return a value
Last edited 12 years ago by zoot (previous) (diff)
Note: See TracTickets for help on using tickets.