Re: Issue 113 Converting Hardcoded Cards to AFs/Trigger
If we had a Drawback version of GainControl, we should be able to get Political Trickery scripted.
- | Open
High Quality Resources for Collectible Card Games and Home of the CCGHQ Team
https://www.slightlymagic.net/forum/
https://www.slightlymagic.net/forum/viewtopic.php?f=52&t=3959
Something else got check in recently that should have used a GainControl drawback. Don't remember what it was. I'll work on this tonight.jeffwadsworth wrote:If we had a Drawback version of GainControl, we should be able to get Political Trickery scripted.
- | Open
Exchange control is a bit trickier than that, since it requires both targets to be legal for the Exchange to happen.jeffwadsworth wrote:If we had a Drawback version of GainControl, we should be able to get Political Trickery scripted.
What about making both Mandatory$ Truefriarsol wrote:Exchange control is a bit trickier than that, since it requires both targets to be legal for the Exchange to happen.jeffwadsworth wrote:If we had a Drawback version of GainControl, we should be able to get Political Trickery scripted.
I'm not sure if Targets being Mandatory helps if one Fizzles and one doesn't. I guess we could change how fizzling works to handle that.jeffwadsworth wrote:What about making both Mandatory$ Truefriarsol wrote:Exchange control is a bit trickier than that, since it requires both targets to be legal for the Exchange to happen.jeffwadsworth wrote:If we had a Drawback version of GainControl, we should be able to get Political Trickery scripted.
I just thought about this again and took a look at the corresponding code. I couldn't find a check for state based effects at the beginning of Phases/Steps, but we really do need them (for cards like Mightstone and Weakstone). Am I missing something or should I add it to handleBeginPhase()?friarsol wrote:Not all Card Draw though right? Just the State based effect at the beginning of your turn?Sloth wrote:Actually they have to be checked at other times too:friarsol wrote:Ah good.
Ideally, state based effects should be checked after each SA finishes resolving completely and at the beginning of Phases/Steps, so it doesn't need to appear 40 times throughout the code. Is there some part of the trigger system that is incapatable with that idea?
- Card draw (Akki Underling)
- Add Mana to Manapool (Omnath, Locus of Mana)
- Something becomes tapped (Maraxus of Keld)
- Counters get removed
Paying costs of non-mana abilities (the last three) shouldn't check state based effects though. Only paying costs of mana abilities should check afterwards (since they don't use the stack).
So really we have:
Phase based effects (card draw/all combat damage is dealt), After an SA resolves, After an SA (and all corresponding triggers) is added to the stack, and after a Mana Ability is activated. Or am I missing some other hidden times?
Yep, I think handleBeginPhase is the right place for that. Considering the recent bug reports of Weakstone and Moat that should do the trick.Sloth wrote:I just thought about this again and took a look at the corresponding code. I couldn't find a check for state based effects at the beginning of Phases/Steps, but we really do need them (for cards like Mightstone and Weakstone). Am I missing something or should I add it to handleBeginPhase()?