23 lines
857 B
Groovy
23 lines
857 B
Groovy
|
[
|
||
|
new MagicSpellCardEvent() {
|
||
|
@Override
|
||
|
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
|
||
|
return new MagicEvent(
|
||
|
cardOnStack,
|
||
|
MagicTargetChoice.TARGET_CREATURE_YOU_CONTROL,
|
||
|
MagicPowerTargetPicker.getInstance(),
|
||
|
this,
|
||
|
"Draw cards equal to the power of target creature\$ you control."
|
||
|
);
|
||
|
}
|
||
|
@Override
|
||
|
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||
|
event.processTargetPermanent(game,new MagicPermanentAction() {
|
||
|
public void doAction(final MagicPermanent creature) {
|
||
|
game.doAction(new MagicDrawAction(event.getPlayer(),creature.getPower()));
|
||
|
}
|
||
|
});
|
||
|
}
|
||
|
}
|
||
|
]
|