Added the possibility to specify a name for Kicker cost and Retrace cost with "name()" keyword, implemented Escape cost with Retrace cost, implemented Fuse cost with Kicker cost, fixed several primitives.

This commit is contained in:
Vittorio Alfieri
2021-02-15 18:41:59 +01:00
parent f383d0b8a5
commit 60ca9e05c0
7 changed files with 190 additions and 139 deletions

View File

@@ -94,10 +94,13 @@ class MTGKickerRule: public MTGPutInPlayRule
public:
int isReactingToClick(MTGCardInstance * card, ManaCost * mana = NULL);
int reactToClick(MTGCardInstance * card);
string alternativeName;
virtual ostream& toString(ostream& out) const;
MTGKickerRule(GameObserver* observer, int _id);
const string getMenuText()
{
if(alternativeName.size())
return alternativeName.c_str();
return "Pay Kicker";
}
virtual MTGKickerRule * clone() const;
@@ -172,10 +175,13 @@ class MTGRetraceRule: public MTGAlternativeCostRule
public:
int isReactingToClick(MTGCardInstance * card, ManaCost * mana = NULL);
int reactToClick(MTGCardInstance * card);
string alternativeName;
virtual ostream& toString(ostream& out) const;
MTGRetraceRule(GameObserver* observer, int _id);
const string getMenuText()
{
if(alternativeName.size())
return alternativeName.c_str();
return "Retrace";
}
virtual MTGRetraceRule * clone() const;