fix windswept_heath.txt missing choice 1, added unearth support without workaround, tweaked alternative cost, added treason/sneak attack ability, added frozen.
This commit is contained in:
@@ -53,8 +53,6 @@ public:
|
||||
intValue = target->getManaCost()->getConvertedCost();
|
||||
}else if (s == "lifetotal"){
|
||||
intValue = target->controller()->life;
|
||||
}else if (s == "sunburst"){
|
||||
intValue = target->costAmount;
|
||||
}else if (s == "odcount"){
|
||||
intValue = target->controller()->opponent()->damageCount;
|
||||
}else if (s == "opponentlifetotal"){
|
||||
@@ -2330,6 +2328,32 @@ class AAUntapper:public ActivatedAbility{
|
||||
}
|
||||
};
|
||||
|
||||
/* Can prevent a card from untapping next untap */
|
||||
class AAFrozen:public ActivatedAbility{
|
||||
public:
|
||||
AAFrozen(int id, MTGCardInstance * card, MTGCardInstance * _target,ManaCost * _cost = NULL, int doTap = 0):ActivatedAbility(id,card, _cost,0,doTap){
|
||||
target = _target;
|
||||
}
|
||||
|
||||
int resolve(){
|
||||
MTGCardInstance * _target = (MTGCardInstance *) target;
|
||||
if (_target){
|
||||
while (_target->next) _target=_target->next; //This is for cards such as rampant growth
|
||||
_target->frozen += 1;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
const char * getMenuText(){
|
||||
return "Freeze";
|
||||
}
|
||||
|
||||
AAFrozen * clone() const{
|
||||
AAFrozen * a = NEW AAFrozen(*this);
|
||||
a->isClone = 1;
|
||||
return a;
|
||||
}
|
||||
};
|
||||
|
||||
// Add life of gives damage if a given zone has more or less than [condition] cards at the beginning of [phase]
|
||||
//Ex : the rack, ivory tower...
|
||||
|
||||
@@ -44,11 +44,10 @@ class MTGCardInstance: public CardPrimitive, public MTGCard, public Damageable {
|
||||
MTGGameZone * currentZone;
|
||||
Pos* view;
|
||||
int X;
|
||||
int costAmount;
|
||||
int frozen;
|
||||
int regenerateTokens;
|
||||
int isToken;
|
||||
int stillInUse();
|
||||
int getCostAmount();
|
||||
Player * lastController;
|
||||
MTGGameZone * getCurrentZone();
|
||||
MTGGameZone * previousZone;
|
||||
@@ -75,7 +74,7 @@ class MTGCardInstance: public CardPrimitive, public MTGCard, public Damageable {
|
||||
int removeType(int value, int removeAll = 0);
|
||||
|
||||
//Combat
|
||||
bool blocked; //Blocked this turn or not?
|
||||
bool blocked; //Blocked this turn or not?
|
||||
MTGCardInstance * defenser;
|
||||
list<MTGCardInstance *>blockers;
|
||||
int attacker;
|
||||
|
||||
@@ -111,8 +111,11 @@ class Constants
|
||||
WILTING = 53,
|
||||
VIGOR = 54,
|
||||
CHANGELING = 55,
|
||||
ABSORB = 56,//this need to be coded for players too "If a source would deal damage"
|
||||
TREASON = 57,
|
||||
UNEARTH = 58,
|
||||
|
||||
NB_BASIC_ABILITIES = 56,
|
||||
NB_BASIC_ABILITIES = 59,
|
||||
|
||||
|
||||
RARITY_S = 'S', //Special Rarity
|
||||
|
||||
@@ -64,6 +64,23 @@ class MTGPersistRule:public MTGAbility{
|
||||
virtual MTGPersistRule * clone() const;
|
||||
};
|
||||
|
||||
class MTGUnearthRule:public MTGAbility{
|
||||
public:
|
||||
MTGUnearthRule(int _id);
|
||||
int receiveEvent(WEvent * event);
|
||||
virtual ostream& toString(ostream& out) const;
|
||||
int testDestroy();
|
||||
virtual MTGUnearthRule * clone() const;
|
||||
};
|
||||
|
||||
class MTGSneakAttackRule:public MTGAbility{
|
||||
public:
|
||||
MTGSneakAttackRule(int _id);
|
||||
int receiveEvent(WEvent * event);
|
||||
virtual ostream& toString(ostream& out) const;
|
||||
int testDestroy();
|
||||
virtual MTGSneakAttackRule * clone() const;
|
||||
};
|
||||
|
||||
class MTGTokensCleanup:public MTGAbility{
|
||||
public:
|
||||
@@ -146,7 +163,6 @@ class MTGDeathtouchRule:public MTGAbility{
|
||||
virtual MTGDeathtouchRule * clone() const;
|
||||
};
|
||||
|
||||
|
||||
/* HUD Display */
|
||||
|
||||
class HUDString {
|
||||
|
||||
Reference in New Issue
Block a user