Skip to content

Commit 2483eae

Browse files
authored
fix:Adds call to combatant.clearMovementHistory on start end end turn handlers (#612)
1 parent 4420801 commit 2483eae

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

module/ui/combat.mjs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -322,6 +322,7 @@ export class FUCombat extends foundry.documents.Combat {
322322
const turns = this.combatants.contents.sort(this._sortCombatants);
323323
if (this.turn !== null) this.turn = Math.clamp(this.turn, 0, turns.length - 1);
324324
this.current = this._getCurrentState(combatant);
325+
325326
// Notify
326327
this.setupTurns();
327328
this.notifyCombatTurnChange();
@@ -334,6 +335,7 @@ export class FUCombat extends foundry.documents.Combat {
334335
}
335336
}
336337

338+
await combatant.clearMovementHistory();
337339
await this._onStartTurn(combatant);
338340
}
339341

@@ -372,6 +374,8 @@ export class FUCombat extends foundry.documents.Combat {
372374
// TODO: Inform user?
373375
}
374376
}
377+
378+
await combatant.clearMovementHistory();
375379
}
376380

377381
/**

0 commit comments

Comments
 (0)