- some dangerous casts Player/MTGCardInstance fixed
- removed typeAsTarget function and replaced with dynamic casting - The test suite passes, but it is possible that I busted some of AI's features :(
This commit is contained in:
@@ -1,17 +1,12 @@
|
||||
#ifndef _TARGETABLE_H_
|
||||
#define _TARGETABLE_H_
|
||||
|
||||
#define TARGET_CARD 1
|
||||
#define TARGET_PLAYER 2
|
||||
#define TARGET_STACKACTION 3
|
||||
|
||||
class Targetable
|
||||
{
|
||||
protected:
|
||||
GameObserver* observer;
|
||||
public:
|
||||
Targetable(GameObserver* observer) : observer(observer) {};
|
||||
virtual int typeAsTarget() = 0;
|
||||
virtual const string getDisplayName() const = 0;
|
||||
inline GameObserver* getObserver() { return observer; };
|
||||
virtual void setObserver(GameObserver*g) { observer = g; };
|
||||
|
||||
Reference in New Issue
Block a user