Added a new keyword "excessdamage" to retrieve theamount of exceeded damage to creature or planeswalker, fixed an issue on planeswalker damage count, added a new keyword "genrand" to generate a random number between 0 and a specific number (e.g. "genrand3"), improved Flip ability in order to allow the flip back from copy for a generic card name (e.g. "flip(myorigname) undocpy)"
This commit is contained in:
@@ -926,6 +926,11 @@ public:
|
||||
e->damage->target->thatmuch = e->damage->damage;
|
||||
e->damage->source->thatmuch = e->damage->damage;
|
||||
this->source->thatmuch = e->damage->damage;
|
||||
if(e->damage->target->life < 0){
|
||||
e->damage->target->exceededDamage = e->damage->target->life;
|
||||
e->damage->source->exceededDamage = e->damage->target->life;
|
||||
this->source->exceededDamage = e->damage->target->life;
|
||||
}
|
||||
triggeredTurn = game->turn;
|
||||
|
||||
return 1;
|
||||
|
||||
@@ -53,6 +53,7 @@ public:
|
||||
vector<string> formattedText;
|
||||
string text;
|
||||
string name;
|
||||
string nameOrig;
|
||||
int init();
|
||||
|
||||
uint8_t colors;
|
||||
|
||||
@@ -27,6 +27,7 @@ public:
|
||||
int nonCombatDamage;
|
||||
int preventable;
|
||||
int thatmuch;
|
||||
int exceededDamage;
|
||||
int lifeLostThisTurn;
|
||||
int lifeGainedThisTurn;
|
||||
DamageableType type_as_damageable;
|
||||
|
||||
Reference in New Issue
Block a user