Casualty is not properly implemented as two separate abilities.
- Dominant language
- Java
- Stars
- 2.4k
- Forks
- 940
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 160
Description
> [702.153a.](https://yawgatog.com/resources/magic-rules/#R702153a) [Casualty](https://yawgatog.com/resources/magic-rules/#casualty) is a keyword that represents two [abilities](https://yawgatog.com/resources/magic-rules/#ability). The first is a [static ability](https://yawgatog.com/resources/magic-rules/#static_ability) that functions while the [spell](https://yawgatog.com/resources/magic-rules/#spell) with [casualty](https://yawgatog.com/resources/magic-rules/#casualty) is on the [stack](https://yawgatog.com/resources/magic-rules/#stack). The second is a [triggered ability](https://yawgatog.com/resources/magic-rules/#triggered_ability) that functions while the [spell](https://yawgatog.com/resources/magic-rules/#spell) with [casualty](https://yawgatog.com/resources/magic-rules/#casualty) is on the [stack](https://yawgatog.com/resources/magic-rules/#stack). [Casualty](https://yawgatog.com/resources/magic-rules/#casualty) N means "As an [additional cost](https://yawgatog.com/resources/magic-rules/#additional_cost) to [cast](https://yawgatog.com/resources/magic-rules/#cast) this [spell](https://yawgatog.com/resources/magic-rules/#spell), [you](https://yawgatog.com/resources/magic-rules/#you_your) may [sacrifice](https://yawgatog.com/resources/magic-rules/#sacrifice) a [creature](https://yawgatog.com/resources/magic-rules/#creature) with [power](https://yawgatog.com/resources/magic-rules/#power) N or greater," and "When [you](https://yawgatog.com/resources/magic-rules/#you_your) [cast](https://yawgatog.com/resources/magic-rules/#cast) this [spell](https://yawgatog.com/resources/magic-rules/#spell), if a [casualty](https://yawgatog.com/resources/magic-rules/#casualty) [cost](https://yawgatog.com/resources/magic-rules/#cost) was paid for it, [copy](https://yawgatog.com/resources/magic-rules/#copy) it. If the [spell](https://yawgatog.com/resources/magic-rules/#spell) has [any targets](https://yawgatog.com/resources/magic-rules/#any_target), [you](https://yawgatog.com/resources/magic-rules/#you_your) may choose new [targets](https://yawgatog.com/resources/magic-rules/#target) for the [copy](https://yawgatog.com/resources/magic-rules/#copy)." Paying a [spell](https://yawgatog.com/resources/magic-rules/#spell)'s [casualty](https://yawgatog.com/resources/magic-rules/#casualty) [cost](https://yawgatog.com/resources/magic-rules/#cost) follows the rules for paying [additional costs](https://yawgatog.com/resources/magic-rules/#additional_cost) in rules [601.2b](https://yawgatog.com/resources/magic-rules/#R6012b) and [601.2f](https://yawgatog.com/resources/magic-rules/#R6012f)-h.
The current implementation is incorrect. When you sacrifice [[Silverquill, the Disputant]] for a Casualty trigger, it should be sacrificed, but without trigger to add a copy of the spell.
I've added a test if anyone wants to take a look at reworking Casualty:
https://github.com/magefree/mage/commit/6ea8b27ffb2d869dbcfb2250e8faedf39b161b82
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the test added in commit 6ea8b27ffb2d869dbcfb2250e8faedf39b161b82 and trace the existing Casualty implementation it exercises. Reproduce the Silverquill, the Disputant case, then verify that sacrificing the creature pays the additional cost while the separate triggered ability adds the spell copy. Done means the added test passes and both Casualty abilities follow the cited rules.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- game-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100