Files
wagic/projects/mtg/include/CardSelectorSingleton.h
Xawotihs 9adb9d625d - reworked the testsuite and the rules (storyflow) to use the same game deserialization code, moved that code to the players and zone classes
- removed every references to the gameobserver singleton. This object can now be instantiated several times as it's needed for minmax. To be able to do that, I mostly added a reference to a gameobserver from any targetable object (cards, players, spells) and abilities.
2011-10-01 13:30:30 +00:00

30 lines
838 B
C++

#ifndef CARDSELECTORSINGLETON_H
#define CARDSELECTORSINGLETON_H
#include "CardSelector.h"
class DuelLayers;
namespace CardSelectorSingleton
{
/*
** CardSelector is essentially a singleton in its usage
** It's not enforced, but it needs to eventually migrate to the real thing
** For now, this function will fake it out - it's up to the client caller to make sure
** that this gets destroyed via a Terminate call (this is currently handled in DualLayers's destructor)
*/
CardSelectorBase* Instance();
/*
** Create the singleton pointer. Instance() isn't valid until this is called.
*/
CardSelectorBase* Create(GameObserver* observer, DuelLayers* inDuelLayers);
/*
** Teardown the singleton pointer instance.
*/
void Terminate();
}
#endif //CARDSELECTORSINGLETON_H