Idea: a manager for "can't untap more than..." effects
Posted: 17 Oct 2016, 09:06
This could be useful for all DotP iterations, so please, don't hesitate to reply even if you are modding DotP2014.
Dovin Baan made me think again about "can't untap more than..." effects. The major problem in coding one of them is that it should interact nicely with other cards with similar effects.
Here's a list of cards with that kind of effect:However, there are many duplicates, so the list could be transformed into two shorter lists: who can be affected and how.
Who:
Some things we need to be careful with:
"who" and "how" in a DuelDataChest register "how" in the current player's data chest if they are affected by it. The manager reads them, combines them, and gives the correct result during the following untap step.
EDIT: The manager is complete. This version is for Magic Duels, feel free to adapt it for earlier versions (I'm pretty sure that the only thing you need to do is to substitute string indexes with numbered indexes).
Use the code here for reference, or download it together with 2 cards I included in the attachment (I haven't included the images).
Dovin Baan made me think again about "can't untap more than..." effects. The major problem in coding one of them is that it should interact nicely with other cards with similar effects.
Here's a list of cards with that kind of effect:However, there are many duplicates, so the list could be transformed into two shorter lists: who can be affected and how.
Who:
- All players
- The controller (Mungha Wurm only)
- Controller's opponents (Dovin Baan only)
- Can't untap more than 1 artifact
- Can't untap more than 2 permanents
- Can't untap more than 1 land
- Can't untap more than 1 creature
Some things we need to be careful with:
- If one of those cards changes controller, the "who" needs to be updated.
- Static Orb and Winter Orb only work untapped.
- Permanents that can't untap during the current untap step shouldn't be selectable. And that's something I have never tested, but, does a permanent forced not to untap through Hold() or TapAndHold() return true if CHARACTERISTIC_DOESNT_UNTAP is checked on it?
If so, then it's easy, we just need to be sure that we check it before it automatically goes away during the untap step.It turns out that the answer to the question is no, so this solution wasn't feasible.
EDIT: The manager is complete. This version is for Magic Duels, feel free to adapt it for earlier versions (I'm pretty sure that the only thing you need to do is to substitute string indexes with numbered indexes).
Use the code here for reference, or download it together with 2 cards I included in the attachment (I haven't included the images).
- MD_TFM_UNTAP_LIMIT_FUNCTIONS.LOL | Open