feat(phase8): complete remaining 3 gaps -- pending types, StackDeck interactive, canvas builder
Pending interaction coverage:
- Add PendingTilePick model (tile-select pause for effects like CloneSpiritAsToken TargetTile)
- Add PendingPlayerPick model (player-select pause for ChannelCardFromZone UnderControlOf: Choice)
- Add PendingRevealChoicePick model (reveal-and-order pause for StackDeck interactive path)
- Add all three as nullable properties on GameState
StackDeckEffect interactive flow:
- Replace random-shuffle fallback with chooser-aware branching
- Self/Opponent chooser: remove top N from deck, emit PendingRevealChoicePick pause
- Random/empty chooser: random shuffle fallback (unchanged)
- Add ResumeRevealChoicePick(): restore deck in chooser's ordered indices; unspecified
cards placed beneath chosen cards preserving relative order
Canvas AbilityBuilder (Phase 4 spec):
- Add @inject IJSRuntime + @implements IAsyncDisposable to AbilityBuilder.razor
- Add sorAdmin.abilityBuilder JS shim in admin.js: non-passive wheel listener (zoom),
pinch-to-zoom via touch distance delta, cleanup on dispose
- Canvas mode toggle button in form toolbar ("Visual Canvas")
- Full canvas layout: left panel (ability list + node palette), main canvas, right inspector
- Dark canvas background (#111827), CSS transform pan+zoom (translate then scale)
- SVG bezier edge overlay connecting node flow (Meta→Range/Trigger→Cost→Cond→ActionGroup
→Actions→Effects, ActionGroup→SubGroups→their Actions→their Effects)
- Node types: Meta (blue), Range (teal), Trigger (purple), Cost (amber), Conditions (yellow),
ActionGroup (dark green), Action (green), Effect (red), SubGroup (dark green), SubGroupAction,
SubGroupEffect -- each draggable, click-to-select
- Inspector panel: inline editing for all node types (type/name/desc, range fields, trigger
event, group logic op, action target selector, effect type picker)
- AutoLayoutAbility() positions nodes on first focus; SetPos() preserves drag positions
- Zoom/pan: toolbar +/- buttons + scroll wheel (via JS) + middle-mouse drag
- OnCanvasWheel [JSInvokable] + DisposeAsync cleanup
- Form view toggle restores full form; JSON preview always visible
Generated with [Claude Code](https://claude.ai/code)
via [Happy](https://happy.engineering)
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Happy <yesreply@happy.engineering>
This commit is contained in:
@@ -126,6 +126,27 @@ public sealed class GameState
|
||||
/// player must select a branch. Paused until chooser submits a <c>game.branch_pick</c>.
|
||||
/// </summary>
|
||||
public Abilities.Models.PendingBranchPick? PendingBranchPick { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Non-null when an effect needs a human to select a specific tile
|
||||
/// (e.g. CloneSpiritAsToken TargetTile destination, RelocateRuin).
|
||||
/// Paused until the chooser submits a <c>game.tile_pick</c> response.
|
||||
/// </summary>
|
||||
public Abilities.Models.PendingTilePick? PendingTilePick { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Non-null when an effect needs a human to select a player
|
||||
/// (e.g. ChannelCardFromZone with UnderControlOf: Choice).
|
||||
/// Paused until the chooser submits a <c>game.player_pick</c> response.
|
||||
/// </summary>
|
||||
public Abilities.Models.PendingPlayerPick? PendingPlayerPick { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Non-null when cards have been revealed face-up and a player must choose their
|
||||
/// ordering (e.g. StackDeckEffect interactive path).
|
||||
/// Paused until the chooser submits a <c>game.reveal_choice_pick</c> response.
|
||||
/// </summary>
|
||||
public Abilities.Models.PendingRevealChoicePick? PendingRevealChoicePick { get; set; }
|
||||
}
|
||||
|
||||
public sealed class PlayerState
|
||||
|
||||
Reference in New Issue
Block a user