feat(combat): expose combat stats in observation snapshot

This commit is contained in:
2026-09-06 13:38:53 +02:00
parent cd796ecffb
commit cd8051f2c4
2 changed files with 221 additions and 0 deletions
+17
View File
@@ -596,6 +596,23 @@ class CombatEngine:
"grappled_with": state.grappled_with,
"moved_this_turn": state.moved_this_turn,
"power_attack": state.power_attack,
"name": state.combatant.name,
"level": state.combatant.level,
"size": state.combatant.size,
"speed_land_ft": state.combatant.speed_land_ft,
"speed_fly_ft": state.combatant.speed_fly_ft,
"ac": {
"total": state.combatant.ac.total,
"touch": state.combatant.ac.touch,
"flat_footed": state.combatant.ac.flat_footed,
},
"saves": {
"fort": state.combatant.saves.fort,
"ref": state.combatant.saves.ref,
"will": state.combatant.saves.will,
},
"cmb": self._maneuver_cmb(state),
"cmd": self._maneuver_cmd(state),
}
def _pair_snapshot(