Fixed some primitives from issue #1085, fixed _BLINK_UEOT_ macro, improved several abilities to allow the usage og "and" option.
This commit is contained in:
@@ -4300,6 +4300,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
Targetable * t = spell ? spell->getNextTarget() : NULL;
|
||||
MTGAbility * a = NEW AADamager(observer, id, card, t, splitDamage[1], NULL, who);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AADamager*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -4619,6 +4625,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
Targetable * t = spell ? spell->getNextTarget() : NULL;
|
||||
MTGAbility * a = NEW AALifer(observer, id, card, t, splitLife[1], false, NULL, who);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AALifer*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -4629,6 +4641,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
Targetable * t = spell ? spell->getNextTarget() : NULL;
|
||||
MTGAbility * a = NEW AALifer(observer, id, card, t, splitSiphonLife[1], true, NULL, who);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AALifer*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -4649,6 +4667,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
Targetable * t = spell ? spell->getNextTarget() : NULL;
|
||||
MTGAbility * a = NEW AADrawer(observer, id, card, t, NULL,splitDraw[1], who,s.find("noreplace") != string::npos);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AADrawer*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -4665,6 +4689,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
Targetable * t = spell ? spell->getNextTarget() : NULL;
|
||||
MTGAbility * a = NEW AADepleter(observer, id, card, t , splitDeplete[1], NULL, who, false, colorrepeat, namerepeat);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AADepleter*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -4681,6 +4711,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
Targetable * t = spell ? spell->getNextTarget() : NULL;
|
||||
MTGAbility * a = NEW AADepleter(observer, id, card, t , splitIngest[1], NULL, who, true, colorrepeat, namerepeat);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AADepleter*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -4710,6 +4746,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
Targetable * t = spell? spell->getNextTarget() : NULL;
|
||||
MTGAbility * a = NEW AAShuffle(observer, id, card, t, NULL, who);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AAShuffle*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -5548,6 +5590,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
{
|
||||
MTGAbility * a = NEW AAFrozen(observer, id, card, target,false);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AAFrozen*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -5557,6 +5605,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
{
|
||||
MTGAbility * a = NEW AAFrozen(observer, id, card, target,true);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AAFrozen*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -5699,6 +5753,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
{
|
||||
MTGAbility * a = NEW AAUntapper(observer, id, card, target);
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AAUntapper*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
@@ -5708,6 +5768,12 @@ MTGAbility * AbilityFactory::parseMagicLine(string s, int id, Spell * spell, MTG
|
||||
{
|
||||
MTGAbility * a = NEW AATapper(observer, id, card, target, NULL, bool(s.find("tap(noevent)") != string::npos));
|
||||
a->oneShot = 1;
|
||||
if(storedAndAbility.size())
|
||||
{
|
||||
string stored = storedAndAbility;
|
||||
storedAndAbility.clear();
|
||||
((AATapper*)a)->andAbility = parseMagicLine(stored, id, spell, card);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user