diff options
author | Shauren <none@none> | 2010-12-22 20:52:47 +0100 |
---|---|---|
committer | Shauren <none@none> | 2010-12-22 20:52:47 +0100 |
commit | 0948fc5bbed08ae6edee4fa1ff86df5cfbffa996 (patch) | |
tree | 12cec534711f07b659ad644dd27bb0a2dabe7d97 /src/server/game/Scripting/ScriptSystem.h | |
parent | 7b4e1c6387a6787c2b2822494abae6b717f24547 (diff) |
Core: Converted (hopefully) all remaining singletons to use ACE_Singleton class
--HG--
branch : trunk
Diffstat (limited to 'src/server/game/Scripting/ScriptSystem.h')
-rw-r--r-- | src/server/game/Scripting/ScriptSystem.h | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/src/server/game/Scripting/ScriptSystem.h b/src/server/game/Scripting/ScriptSystem.h index 52401502c83..27a20f009a6 100644 --- a/src/server/game/Scripting/ScriptSystem.h +++ b/src/server/game/Scripting/ScriptSystem.h @@ -4,6 +4,7 @@ #ifndef SC_SYSTEM_H #define SC_SYSTEM_H +#include <ace/Singleton.h> #define TEXT_SOURCE_RANGE -1000000 //the amount of entries each text source has available @@ -51,13 +52,10 @@ struct StringTextData class SystemMgr { - public: - - SystemMgr(); + friend class ACE_Singleton<SystemMgr, ACE_Null_Mutex>; + SystemMgr() {} ~SystemMgr() {} - - static SystemMgr& Instance(); - + public: //Maps and lists typedef UNORDERED_MAP<int32, StringTextData> TextDataMap; typedef UNORDERED_MAP<uint32, std::vector<ScriptPointMove> > PointMoveMap; @@ -97,6 +95,6 @@ class SystemMgr PointMoveMap m_mPointMoveMap; //coordinates for waypoints }; -#define sScriptSystemMgr SystemMgr::Instance() +#define sScriptSystemMgr (*ACE_Singleton<SystemMgr, ACE_Null_Mutex>::instance()) #endif |