- Added Dr Solomat's TEMPEST expansion - Added Sacrifice as part of the cost of activated abilities. Making it work as an extra cost for "put in play" still requires some work though. "Render" methods need to be written correctly - Added cards with sacrifice in the existing sets. Most of them need testing...
49 lines
1.1 KiB
C++
49 lines
1.1 KiB
C++
#ifndef _EXTRACOST_H_
|
|
#define _EXTRACOST_H_
|
|
|
|
#include <vector>
|
|
using std::vector;
|
|
|
|
class TargetChooser;
|
|
class MTGCardInstance;
|
|
class MTGAbility;
|
|
|
|
class ExtraCost{
|
|
public:
|
|
TargetChooser * tc;
|
|
MTGCardInstance * source;
|
|
ExtraCost(TargetChooser *_tc = NULL);
|
|
virtual int setPayment(MTGCardInstance * card) = 0;
|
|
virtual int isPaymentSet() = 0;
|
|
virtual int doPay() = 0;
|
|
virtual void Render(){};
|
|
virtual int setSource(MTGCardInstance * _source);
|
|
};
|
|
|
|
class ExtraCosts{
|
|
public:
|
|
vector<ExtraCost *>costs;
|
|
MTGCardInstance * source;
|
|
MTGAbility * action;
|
|
ExtraCosts();
|
|
void Render();
|
|
int tryToSetPayment(MTGCardInstance * card);
|
|
int isPaymentSet();
|
|
int doPay();
|
|
int reset();
|
|
int setAction(MTGAbility * _action, MTGCardInstance * _source);
|
|
void Dump();
|
|
};
|
|
|
|
class SacrificeCost: public ExtraCost{
|
|
public:
|
|
MTGCardInstance * target;
|
|
SacrificeCost(TargetChooser *_tc = NULL);
|
|
virtual int setPayment(MTGCardInstance * card);
|
|
virtual int isPaymentSet();
|
|
virtual int doPay();
|
|
virtual void Render();
|
|
virtual int setSource(MTGCardInstance * _source);
|
|
};
|
|
|
|
#endif |