Erwan
- fixed issue 595 (MaxCast not working). Root cause was the stupidest typo ever in the code (maxCost instead of maxCast...) - fixed an issue with Storm mentioned by zethfox (was counting only spells played by current player) - Moved "max lands per turn" rule outside of the code (yay!) Please be sure to update your Rules folder!
This commit is contained in:
@@ -10,11 +10,6 @@ class PlayRestriction
|
||||
{
|
||||
|
||||
public:
|
||||
enum
|
||||
{
|
||||
LANDS_RULE_ID,
|
||||
UNDEF_ID
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
@@ -23,12 +18,11 @@ public:
|
||||
NO_OPINION
|
||||
};
|
||||
|
||||
unsigned int id;
|
||||
TargetChooser * tc;
|
||||
|
||||
virtual int canPutIntoZone(MTGCardInstance * card, MTGGameZone * destZone) = 0;
|
||||
|
||||
PlayRestriction(unsigned int id, TargetChooser * tc);
|
||||
PlayRestriction(TargetChooser * tc);
|
||||
~PlayRestriction();
|
||||
};
|
||||
|
||||
@@ -41,7 +35,7 @@ public:
|
||||
};
|
||||
int maxPerTurn;
|
||||
MTGGameZone * zone;
|
||||
MaxPerTurnRestriction(unsigned int id, TargetChooser * tc, int maxPerTurn, MTGGameZone * zone);
|
||||
MaxPerTurnRestriction(TargetChooser * tc, int maxPerTurn, MTGGameZone * zone);
|
||||
int canPutIntoZone(MTGCardInstance * card, MTGGameZone * destZone);
|
||||
};
|
||||
|
||||
@@ -51,7 +45,8 @@ class PlayRestrictions
|
||||
protected:
|
||||
vector<PlayRestriction *>restrictions;
|
||||
public:
|
||||
PlayRestriction * getRestrictionById(unsigned int id);
|
||||
MaxPerTurnRestriction * getMaxPerTurnRestrictionByTargetChooser(TargetChooser * tc);
|
||||
|
||||
void addRestriction(PlayRestriction * restriction);
|
||||
void removeRestriction(PlayRestriction * restriction);
|
||||
int canPutIntoZone(MTGCardInstance * card, MTGGameZone * destZone);
|
||||
|
||||
Reference in New Issue
Block a user