Skip to content

Show commander tax in perpetual mana cost overlay#10258

Open
MostCromulent wants to merge 1 commit intoCard-Forge:masterfrom
MostCromulent:commander-tax-overlay
Open

Show commander tax in perpetual mana cost overlay#10258
MostCromulent wants to merge 1 commit intoCard-Forge:masterfrom
MostCromulent:commander-tax-overlay

Conversation

@MostCromulent
Copy link
Copy Markdown
Contributor

Summary

  • Commander tax isn't technically a perpetual effect, but the perpetual overlay was added to answer "what does this card actually cost?" — commander tax is the most common reason a commander's cost differs from its printed cost, so it fits naturally here and a separate overlay setting isn't justified
  • When the "perpetual mana cost" overlay is enabled, commanders in the command zone now display their mana cost including accumulated commander tax ({2} per previous cast from command zone)
  • The tax is layered dynamically on top of any existing perpetual cost adjustments in the getter, keeping the perpetual calculation pipeline unchanged

Design notes

Scope: The overlay shows permanent/intrinsic modifiers only (perpetual effects + commander tax), not external battlefield-state cost modifiers like Foundry Inspector. Similarly, cards that specifically offset commander tax — like Myth Unbound ({1} less per cast) or Liesa, Shroud of Dusk (pay life instead of tax) — are not reflected in the overlay. This is an existing limitation of the perpetual overlay — it has never accounted for external modifiers — and commander tax doesn't change that.

View update trigger: The mana cost overlay reads from a cached trackable property, so it needs an explicit updateManaCostForView() call to refresh. Three locations were considered:

  • Player.incCommanderCast() — card is on the stack when this fires, so the zone-gated getter returns base cost (no effect)
  • GameAction.changeZone() — multiple branches need the trigger, and setPerpetual() fires before the zone is set
  • Card.setZone() — fires after zone assignment, single point for all transitions, gated behind isCommander(), consistent with the 50+ existing view.update*() calls in Card.java

Card.setZone() was chosen for simplicity and completeness.


🤖 Generated with Claude Code

When the "perpetual mana cost" overlay is enabled, commanders in the
command zone now show their mana cost including accumulated commander
tax ({2} per previous cast). The tax is layered dynamically on top of
any existing perpetual cost adjustments in the getter, keeping the
perpetual calculation pipeline unchanged.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants