HomeWildfire Games

React to target death properly when chasing

Description

React to target death properly when chasing

Differential Revision: https://code.wildfiregames.com/D2517
Reviewed by: Freagarach
Comments by: elexis, Stan
Fixes: #5610 #5656

Introduce likelyFailure check in the movementupdate for chasing state missing since rP22526.
Use new order and substate for Chasing to get into the wanted range and avoid that way issue with running - walking tracking or animation variants.

Fixing issue when attacker would not react to the death of the target while chasing it in stances where results for abandoning chasing are always false and also do not rely on timer ending chasing for the rest of stances.

Event Timeline

@Angen I'm not sure when an error was introduced, but at least the related code was added here. When I run the game:

pyrogenesis -autostart=random/elephantine -autostart-seed=0 -autostart-aiseed=0 -autostart-ai=1:petra -autostart-ai=2:petra -autostart-players=2 -autostart-nonvisual

I get the error:

ERROR: Tried to process unhandled event 'Order.MoveToChasingPoint' in state 'INDIVIDUAL.COMBAT.FINDINGNEWTARGET'
Freagarach added a subscriber: Freagarach.EditedOct 22 2020, 8:24 AM

How far into that game did you get it? (For I let it play for half an hour and did not see the error.)

@vladislavbelov thank you, you can mark this red, I try to check this evening

I reproduced it once from 6 runs and even that one case was non visual so I do not have replay

the reason it does have that order only in one state is it should never happen to get that order unless in particular state but it somehow happened

With the Seed and AISeed the game should be perfectly reproducible, right? (And those are written on game init, IIRC.)

well. i have got the replay and found when it happens but i cant reproduce it outside the replay with entity promotion, entity death or ownership change.