mage icon indicating copy to clipboard operation
mage copied to clipboard

Abilities with setTargetPointer set should throw a Wrong Code Usage error if you try to addTarget.

Open Grath opened this issue 1 month ago • 3 comments

Image

Couldn't blatantly see what's wrong in the code, but this is definitely very wrong.

Grath avatar Nov 21 '25 02:11 Grath

cause GainLifeControllerTriggeredAbility used with setTargetPointer on trigger (set player as target) - so target changed from trigger - to doifcostpay - to addcounter. Try to disable it:

Image

JayDi85 avatar Nov 21 '25 11:11 JayDi85

Also it possible to override GainLifeControllerTriggeredAbility.addTarget to verify check like “if setTargetPointer is true then raise error “Wrong code usage: ability uses auto target, do not add it manually”. Maybe another cards bugged too. Same logic can be used to verify all other abilities with auto target setup (e.g. with setTargetPointer).

JayDi85 avatar Nov 21 '25 11:11 JayDi85

Fixed Cradle of Vitality, renamed issue to reflect the resulting further work this revealed.

Grath avatar Nov 21 '25 16:11 Grath