- Adding cycling. Check Akroma's vengeance in ONS for an example. Note that this uses autohand instead of auto, this is important! You can also use autograveyard. 
- All "auto" activated abilities should work with autohand, so this is not only for cycling, but could be used for other abilities as well. For example autohand={3}:cycling can also be written autohand={3}{S}:Draw:1
This commit is contained in:
wagic.the.homebrew@gmail.com
2009-12-12 11:09:13 +00:00
parent 3d23a4f3c8
commit 512f649147
15 changed files with 164 additions and 30 deletions
+30
View File
@@ -164,6 +164,36 @@ ostream& MTGAttackRule::toString(ostream& out) const
}
OtherAbilitiesEventReceiver::OtherAbilitiesEventReceiver(int _id):MTGAbility(_id,NULL){
}
int OtherAbilitiesEventReceiver::receiveEvent(WEvent *e){
if (WEventZoneChange* event = dynamic_cast<WEventZoneChange*>(e)) {
if (event->to && (event->to != event->from)){
GameObserver * g = GameObserver::GetInstance();
for (int i = 0; i < 2; ++i){
if (event->to == g->players[i]->game->inPlay) return 0;
}
AbilityFactory af;
af.magicText(g->mLayers->actionLayer()->getMaxId(), NULL, event->card, 1, 0,event->to);
return 1;
}
}
return 0;
}
int OtherAbilitiesEventReceiver::testDestroy(){
return 0;
}
OtherAbilitiesEventReceiver * OtherAbilitiesEventReceiver::clone() const{
OtherAbilitiesEventReceiver * a = NEW OtherAbilitiesEventReceiver(*this);
a->isClone = 1;
return a;
}
MTGBlockRule::MTGBlockRule(int _id):MTGAbility(_id,NULL){
aType=MTGAbility::MTG_BLOCK_RULE;
}