CameronJung / ChopperTankFlak

A simple rock-paper-scissors strategy game
0 stars 0 forks source link

AI will sometimes pass up an opportunity to destroy a unit #24

Open CameronJung opened 3 months ago

CameronJung commented 3 months ago

Sometimes the AI will move a unit next to one of the player's units, but not destroy it.

CameronJung commented 3 months ago

This bug is rare, moving forward accounts of its occurrence should be documented here to pin down the cause.

CameronJung commented 2 months ago

While play testing Operation: Flyswatter I observed this bug, where an AI helicopter didn't attack an adjacent player's tank. The tank was in a canyon. This might mean that the AI isn't recognizing attacks that are on tiles the AI's unit can't traverse.

CameronJung commented 6 days ago

I had another thought on this issue recently too. Currently, attack commands have their safety assessed for the hex of the target. Of course, this is erroneous since the attacking unit doesn't move to where the destroyed unit is, but the implications are usually close enough to not matter. It might be the case that moving next to the space of the unit keeps it out of harms way, but the would be victim is on a hex that is covered by another unit.