Menu

Submission for Drifting Djinn

71

Config

name=Drifting Djinn
url=http://magiccards.info/us/en/71.html
image=http://magiccards.info/scans/en/us/71.jpg
value=2.880
rarity=R
type=Creature
subtype=Djinn
cost={4}{U}{U}
pt=5/5
ability=flying,cycling {2}
timing=main
requires_groovy_code

Script

[
    new MagicAtUpkeepTrigger() {
        @Override
        public MagicEvent executeTrigger(
                final MagicGame game,
                final MagicPermanent permanent,
                final MagicPlayer upkeepPlayer) {
            return permanent.isController(upkeepPlayer) ?
                new MagicEvent(
                    permanent,
                    new MagicMayChoice(
                        new MagicPayManaCostChoice(MagicManaCost.create("{1}{U}"))
                    ),
                    this,
                    "PN may\$ pay {1}{U}\$. If you don't, sacrifice SN."
                ) :
                MagicEvent.NONE;
        }
        @Override
        public void executeEvent(final MagicGame game, final MagicEvent event) {
            if (event.isNo()) {
                game.doAction(new MagicSacrificeAction(event.getPermanent()));
            }
        }
    }
]
Pushed