Add combatant side assignment for encounter difficulty
Combatants can now be assigned to party or enemy side via a toggle in the difficulty breakdown panel. Party-side NPCs subtract their XP from the encounter total, letting allied NPCs reduce difficulty. PCs default to party, non-PCs to enemy — users who don't use sides see no change. Side persists across reload and export/import. Closes #22 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -101,6 +101,13 @@ export interface CrSet {
|
||||
readonly newCr: string | undefined;
|
||||
}
|
||||
|
||||
export interface SideSet {
|
||||
readonly type: "SideSet";
|
||||
readonly combatantId: CombatantId;
|
||||
readonly previousSide: "party" | "enemy" | undefined;
|
||||
readonly newSide: "party" | "enemy";
|
||||
}
|
||||
|
||||
export interface ConditionAdded {
|
||||
readonly type: "ConditionAdded";
|
||||
readonly combatantId: CombatantId;
|
||||
@@ -161,6 +168,7 @@ export type DomainEvent =
|
||||
| RoundRetreated
|
||||
| AcSet
|
||||
| CrSet
|
||||
| SideSet
|
||||
| ConditionAdded
|
||||
| ConditionRemoved
|
||||
| ConcentrationStarted
|
||||
|
||||
Reference in New Issue
Block a user