Files
wagic/projects/mtg/include/PhaseRing.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

35 lines
717 B
C++

#ifndef _PHASERING_H_
#define _PHASERING_H_
#include <list>
using std::list;
/*
The class that handles the phases of a turn
*/
class Player;
class Phase{
public:
int id;
Player * player;
Phase(int id, Player *player):id(id),player(player){};
};
class PhaseRing{
public:
list<Phase *> ring;
list<Phase *>::iterator current;
Phase * getCurrentPhase();
Phase * forward();
Phase * goToPhase(int id, Player * player);
PhaseRing(Player* players[], int nbPlayers=2);
~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);
};
#endif