Project

General

Profile

Bug #405

approachSquaresWithinRange function under Behaviors folder produces strange results

Added by Frank Fernandez 2 months ago. Updated about 2 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Start date:
10/10/2025
Due date:
% Done:

0%

Estimated time:

Description

While working on the ranged attack behavior, I've been getting weird results from what the approachSquaresWithinRange function calculates. For ranged attacks, it always seems to think that the enemy in question has no valid options other than remaining where it is. I decided to make sure I hadn't caused some oddity with the calculation by testing the results on an older behavior, in this case AdvanceAndMelee, but the outcome was still strange, such as only highlighting a square to one side of the enemy rather than all possible movement toward a player or even logical movement toward a player (in the case of AdvanceAndMelee, the suggested sidestep was farther from where the player was in that moment).

Possible that I am misunderstanding something, but this seems off.

Also available in: Atom PDF