CDA
CDA works by using "cdaactive" keyword on PT changes. Instead of granting bonus, we modify the orig power and toughness since they are dynamic PT. cdaactive are for cards like maro, tarmogoyf, etc. To Follow/To Do: Additional Tests and other bug fix
This commit is contained in:
@@ -68,7 +68,7 @@ MTGCardInstance::MTGCardInstance(MTGCard * card, MTGPlayerCards * arg_belongs_to
|
||||
|
||||
void MTGCardInstance::applyPTL()
|
||||
{
|
||||
//7a ??how to add cda(Characteristic Defining Ability)??
|
||||
//7a ??(Characteristic Defining Ability)??
|
||||
power = origpower;
|
||||
toughness = origtoughness;
|
||||
//7b
|
||||
@@ -80,17 +80,15 @@ void MTGCardInstance::applyPTL()
|
||||
//7c - 7d shared?
|
||||
power += pbonus;
|
||||
toughness += tbonus;
|
||||
life = toughness;
|
||||
//7e switch is last
|
||||
if (isPTswitch)
|
||||
{
|
||||
oldP = power;
|
||||
oldT = toughness;
|
||||
this->addToToughness(oldP);
|
||||
this->addToToughness(-oldT);
|
||||
this->power = oldT;
|
||||
toughness = oldP;
|
||||
power = oldT;
|
||||
}
|
||||
/* end */
|
||||
life = toughness;
|
||||
doDamageTest = 1;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user