mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-24 06:06:23 +00:00
feat(Core/Misc): remove and replace ACE_Singleton (#2418)
This commit is contained in:
@@ -45,6 +45,12 @@ LFGMgr::~LFGMgr()
|
||||
delete itr->second;
|
||||
}
|
||||
|
||||
LFGMgr* LFGMgr::instance()
|
||||
{
|
||||
static LFGMgr instance;
|
||||
return &instance;
|
||||
}
|
||||
|
||||
void LFGMgr::_LoadFromDB(Field* fields, uint64 guid)
|
||||
{
|
||||
if (!fields)
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
#ifndef _LFGMGR_H
|
||||
#define _LFGMGR_H
|
||||
|
||||
#include <ace/Singleton.h>
|
||||
#include "DBCStructure.h"
|
||||
#include "Field.h"
|
||||
#include "LFG.h"
|
||||
@@ -379,8 +378,6 @@ struct LFGDungeonData
|
||||
|
||||
class LFGMgr
|
||||
{
|
||||
friend class ACE_Singleton<LFGMgr, ACE_Null_Mutex>;
|
||||
|
||||
private:
|
||||
LFGMgr();
|
||||
~LFGMgr();
|
||||
@@ -401,6 +398,8 @@ class LFGMgr
|
||||
RBUsedDungeonsSet RBUsedDungeonsStore[2]; // for 2 factions
|
||||
|
||||
public:
|
||||
static LFGMgr* instance();
|
||||
|
||||
// Functions used outside lfg namespace
|
||||
void Update(uint32 diff, uint8 task);
|
||||
|
||||
@@ -590,5 +589,6 @@ class LFGMgr
|
||||
|
||||
} // namespace lfg
|
||||
|
||||
#define sLFGMgr ACE_Singleton<lfg::LFGMgr, ACE_Null_Mutex>::instance()
|
||||
#define sLFGMgr lfg::LFGMgr::instance()
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user