mage icon indicating copy to clipboard operation
mage copied to clipboard

Undiscovered Paradise and Land Tax interaction not working

Open skiztik opened this issue 7 years ago • 4 comments

Land tax is not triggering when this happens: I have equal numbers of lands as my opponent on his EOT, one of which is an undiscovered paradise. I tap paradise, which reads "Add one mana of any color. During your next untap step, as you untap your permanents, return Undiscovered Paradise to its owner's hand." on my untap, paradise returns to my hand, and land tax fails to trigger in my upkeep. I know paradise is returning at the proper time, because of the interaction between paradise and stasis (it stays in play, tapped), so I suspect either land tax, or just the entire "beginning of turn check for triggers" is not working correctly.

skiztik avatar Sep 20 '18 08:09 skiztik

Yep, still broken.

Zerrisx avatar Jul 13 '20 19:07 Zerrisx

@awjackson @Alex-Vasile: I would like to dig a little bit into the source code of Xmage, Could you provide some more description of how this could be implemented?

Below @awjackson explanation from my previous ticket (#9537) :

The problem is that Undiscovered Paradise is implemented in xmage as a delayed triggered ability (based on the printed text of the card, which like many pre-6ED cards is significantly different from the Oracle text) This is both incorrect to the Oracle text and doesn't work under the rules of Magic (which is exactly why the Oracle text is different) because players never get priority during the untap step and therefore triggered abilities can never be put on the stack then. In xmage, Undiscovered Paradise's triggered ability is checked in the untap step but it doesn't actually fire until the upkeep step, at the same time Land Tax's trigger fires, so when Land Tax's intervening if clause is checked the land hasn't been returned yet.

I think Undiscovered Paradise needs to be reimplemented using some kind of special snowflake code in PlayerImpl.untap.

I would try to find PlayerImpl.untap to understand better hot it works.

Thanks!

gotoco avatar Sep 19 '22 02:09 gotoco

@awjackson @Alex-Vasile: I would like to dig a little bit into the source code of Xmage, Could you provide some more description of how this could be implemented?

Below @awjackson explanation from my previous ticket (#9537) :

The problem is that Undiscovered Paradise is implemented in xmage as a delayed triggered ability (based on the printed text of the card, which like many pre-6ED cards is significantly different from the Oracle text) This is both incorrect to the Oracle text and doesn't work under the rules of Magic (which is exactly why the Oracle text is different) because players never get priority during the untap step and therefore triggered abilities can never be put on the stack then. In xmage, Undiscovered Paradise's triggered ability is checked in the untap step but it doesn't actually fire until the upkeep step, at the same time Land Tax's trigger fires, so when Land Tax's intervening if clause is checked the land hasn't been returned yet. I think Undiscovered Paradise needs to be reimplemented using some kind of special snowflake code in PlayerImpl.untap.

I would try to find PlayerImpl.untap to understand better hot it works.

Thanks!

PlayerImpl.untap() is here: https://github.com/magefree/mage/blob/b14af422804fdd92b1973d139c919e66348730e2/Mage/src/main/java/mage/players/PlayerImpl.java#L1798

I can't comment beyond that since I haven't looked at this portion of the code before.

Alex-Vasile avatar Sep 19 '22 02:09 Alex-Vasile

Thank you for the suggestion will try to learn something from that function and maybe figure out the way to fix it. Thanks!

gotoco avatar Sep 19 '22 03:09 gotoco