Files
wagic/projects/mtg/include/DamageResolverLayer.h
jean.chalard 3349f974f1 J :
* New interface.
* This breaks a lot of things. It is not feature-equivalent. It
  probably doesn't compile under windows and doesn't work on PSP.
* Damage is not resolved any more. This will have to be fixed.
* Blockers can't be ordered any more. This will have to be fixed.
* A lot of new art is included.
2009-08-22 05:59:43 +00:00

54 lines
1.4 KiB
C++

#ifndef _DAMAGERESOLVERLAYER_H_
#define _DAMAGERESOLVERLAYER_H_
#include "../include/PlayGuiObjectController.h"
class MTGCardInstance;
class DamagerDamaged;
class DamageStack;
class DamageResolverLayer:public PlayGuiObjectController{
protected:
GameObserver* game;
int trampleDamage();
void updateAllCoordinates();
public:
int buttonOk;
int orderingIsNeeded;
int currentPhase;
int remainingDamageSteps;
Player * currentChoosingPlayer;
DamageStack * damageStack;
DamagerDamaged * currentSource;
DamageResolverLayer(GameObserver* game);
int init();
int initResolve();
Player * whoSelectsDamagesDealtBy(MTGCardInstance * card);
int addAutoDamageToOpponents(MTGCardInstance * card);
DamagerDamaged * addIfNotExists(MTGCardInstance * card, Player * selecter);
int addDamager(MTGCardInstance * card, Player * selecter);
int updateCoordinates(MTGCardInstance * card);
DamagerDamaged * findByCard(MTGCardInstance * card);
int canStopDealDamages();
int resolveDamages();
int isOpponent(DamagerDamaged * a, DamagerDamaged * b);
int nextPlayer();
virtual void Update(float dt);
virtual bool CheckUserInput(u32 key);
virtual void Render();
int isDisplayed(){return mCount;};
int autoOrderBlockers();
bool blockersOrderingDone();
bool clickDamage(DamagerDamaged * current);
bool clickDamage(MTGCardInstance * c);
bool clickReorderBlocker(MTGCardInstance * blocker);
bool checkUserInputOrderBlockers(u32 key);
};
#endif