zpos and zone display

added zone position (adjust dynamically), also inverts the display of
the zone so we always get the top/recent one... the library zpos is
inverted so if we choose to target the top 5 zpos like
target(*[zpos>=5|mylibrary), it will do from top to bottom... this is
only for AI so we can add alternate code for them since they cant use
reveal atm, we can make them target within allowed range...
Also this commit disabled the  new legend and planeswalker rule since it
conflicts with reveal ability, unless I/We figure it out, I recommend to
use the old one...
This commit is contained in:
Anthony Calosa
2017-02-14 22:30:50 +08:00
parent 2d383e237f
commit 01fdcfdfec
9 changed files with 104 additions and 19 deletions

View File

@@ -672,6 +672,16 @@ void GameObserver::gameStateBasedEffects()
for (int i = 0; i < ManaCost::MANA_PAID_WITH_BESTOW +1; i++)
card->alternateCostPaid[i] = 0;
}
//test zone position
if(card && (isInGrave(card)||isInHand(card)||isInExile(card)))
{
card->zpos = w+1;
}
else if(card && (isInLibrary(card)))
{//invert so we get the top one...
int onum = w+1;
card->zpos = abs(onum - zone->nb_cards)+1;
}
}