Archers won't attack the "first" monster when set to first

Bugs that are fixed (or that we think are fixed) will be moved into this sub-forum for organizational purposes. If you find that one of these bugs is still active, please start a new thread in the main bug report forum and link to the older thread in this sub-forum. Thanks!

Archers won't attack the "first" monster when set to first

Postby Alumina » Wed Feb 22, 2012 9:10 pm

I'm not sure if this is a bug or just some weird AI logic but this has cost me a perfect more than once so:

While on "the way out" mission on extreme difficulty the archers set to the "first" logic will absolutely refuse to attack the monster that is actually "first" after I use pushback. (by "first" I'm assuming that means "first monster in a line of monsters" because I don't feel like it's "closest to azra"). This happens pretty much every time something nears azra and then I use pushback. After a while (after the monster(s) gets to azra) it'll fix itself.
Image

Image


it's version 0.8.9 on windows.
Alumina
 
Posts: 12
Joined: Tue Feb 14, 2012 4:47 pm

Re: Archers won't attack the "first" monster when set to fir

Postby larsiusprime » Thu Feb 23, 2012 9:51 am

I think it's a problem with pushback'ed enemies not calculating their distance to Azra correctly.

Will try to fix for version 0.9.0
larsiusprime
 
Posts: 807
Joined: Mon Feb 13, 2012 10:13 am

Re: Archers won't attack the "first" monster when set to fir

Postby larsiusprime » Thu Feb 23, 2012 10:22 am

Okay, reproduced the bug with the following observations:

I had a ranger in place and waited until I had a group of worms and vanilla revenant grouped together, with some of the worms in front, then pushbacked.

Before the pushback, the ranger was targeting the worms closest to Azra.
After the pushback, the ranger was targeting the vanilla revenant closest to Azra and ignoring the worms that were closer to her.

Can you confirm this sort of thing? That when rangers mis-target "first", they are still targeting the first in a given group of enemies, and the enemies they should be targeting instead belong to a different enemy type? And is that other enemy type also one that moves faster?

If this is what's happening to everyone else, this leads me to believe that the error is in improperly calculating how far an enemy has been pushed back. Ie, they're all pushed back X tiles, but for say the worms who move faster, it might be multiplying X tiles by their speed, and thinking they've gone back further and so the vanilla revenant are now the "closest."
larsiusprime
 
Posts: 807
Joined: Mon Feb 13, 2012 10:13 am

Re: Archers won't attack the "first" monster when set to fir

Postby larsiusprime » Thu Feb 23, 2012 11:30 am

Nope, that's not it. Okay, trying something else...
larsiusprime
 
Posts: 807
Joined: Mon Feb 13, 2012 10:13 am

Re: Archers won't attack the "first" monster when set to fir

Postby Alumina » Thu Feb 23, 2012 11:43 am

After I did more testing I'm not quite sure if that happens exclusively. Followed what you did, waited until worms went ahead of a another, slower group of monsters, then used pushback. Before the archer targeted what was "first", but afterward she stopped doing that.

Image
Image
In this case, wouldn't the archer be attacking the vanilla ones closer to Azra, instead of the guys all the way back near the spawn point?

Image
She doesn't target the ranged reverent here, either.


Heh, thanks for answering so quickly and trying to find the source of this problem. It's definitely a nice refresher coming from games where they don't give a crap about fixing anything.

Edit: oh didn't see that new post lol
Alumina
 
Posts: 12
Joined: Tue Feb 14, 2012 4:47 pm

Re: Archers won't attack the "first" monster when set to fir

Postby larsiusprime » Thu Feb 23, 2012 1:01 pm

Found the real bug:

I turned on visual debugging to display the remaining distance as a text field on each monster. After you pushback, each distance value changes from something normal and expected to "NaN", ie, Not a Number. This happens when you do something bad, like dividing by zero.

So..... after pushback, ALL monsters are the same infinite distance from Azra. It's interesting that the logic still "kinda" works after such a massive bug, but this look like the cause.
larsiusprime
 
Posts: 807
Joined: Mon Feb 13, 2012 10:13 am

Re: Archers won't attack the "first" monster when set to fir

Postby larsiusprime » Thu Feb 23, 2012 1:30 pm

Bug is "fixed." NaN error fixed, and can't reproduce behavior under my old repro scenario. There's always the possibility of some edge case that this doesn't cover, but I think I've solved the worst of it.

Update patch release candidate will go up on the test server on Friday, and the public update patch will go out Monday.
larsiusprime
 
Posts: 807
Joined: Mon Feb 13, 2012 10:13 am

Re: Archers won't attack the "first" monster when set to fir

Postby Alumina » Fri Feb 24, 2012 5:34 pm

I see. Thanks for fixing it, although honestly I'm more impressed that the AI still kinda worked even with a NaN thrown around like that, lol.
Alumina
 
Posts: 12
Joined: Tue Feb 14, 2012 4:47 pm


Return to Fixed Bugs

Who is online

Users browsing this forum: No registered users and 0 guests