Erwan
- Fixed empty ActionStack "interrupt" messages - If no attackers are declared, go straight to Combat end phase - Once First strike damage is declared, attacking player needs to "actively" request a next phase event to go to the next damage step - Second Damage step is called "Combat Damage (2)" - UserRequestNextPhase is to be used knowing that it might not succeed - Step change for GuiCombat is now computed at GameObserver::nextGamePhase Note: Combat damage to creatures is not assigned when AI attacks. As this seems to be a problem with the previous SVN version, I4m still committing this change
This commit is contained in:
@@ -66,6 +66,7 @@ class Interruptible: public PlayGuiObject, public Targetable{
|
||||
class NextGamePhase: public Interruptible {
|
||||
public:
|
||||
int resolve();
|
||||
bool extraDamagePhase();
|
||||
void Render();
|
||||
virtual ostream& toString(ostream& out) const;
|
||||
NextGamePhase(int id);
|
||||
|
||||
@@ -30,6 +30,7 @@ public:
|
||||
|
||||
ActionLayer * actionLayer();
|
||||
ActionStack * stackLayer();
|
||||
GuiCombat * combatLayer();
|
||||
void init();
|
||||
virtual void Update(float dt, Player * player);
|
||||
void CheckUserInput(int isAI);
|
||||
|
||||
@@ -31,6 +31,7 @@ class GuiCombat : public GuiLayer
|
||||
~GuiCombat();
|
||||
virtual void Update(float dt);
|
||||
virtual void Render();
|
||||
bool clickOK();
|
||||
virtual bool CheckUserInput(u32 key);
|
||||
virtual int receiveEventPlus(WEvent* e);
|
||||
virtual int receiveEventMinus(WEvent* e);
|
||||
|
||||
@@ -27,7 +27,7 @@ class MTGAttackRule:public MTGAbility{
|
||||
virtual ostream& toString(ostream& out) const;
|
||||
MTGAttackRule(int _id);
|
||||
const char * getMenuText(){return "Attacker";}
|
||||
void Update(float dt);
|
||||
int receiveEvent(WEvent * event);
|
||||
virtual MTGAttackRule * clone() const;
|
||||
};
|
||||
|
||||
|
||||
@@ -19,6 +19,8 @@ class Phase{
|
||||
};
|
||||
|
||||
class PhaseRing{
|
||||
private:
|
||||
static bool extraDamagePhase(int id);
|
||||
public:
|
||||
list<Phase *> ring;
|
||||
list<Phase *>::iterator current;
|
||||
@@ -30,6 +32,8 @@ class PhaseRing{
|
||||
int addPhase(Phase * phase);
|
||||
int addPhaseBefore(int id, Player* player,int after_id, Player * after_player, int allOccurences = 1);
|
||||
int removePhase (int id, Player * player, int allOccurences = 1);
|
||||
static const char * phaseName(int id);
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user