2022-03-05 12:44:06 +02:00
|
|
|
|
|
|
|
#include <boost/unordered_map.hpp>
|
|
|
|
|
2022-03-05 19:59:39 +02:00
|
|
|
#include <common/stl.h>
|
2022-03-05 12:44:06 +02:00
|
|
|
|
|
|
|
class CDragonLair
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
CDragonLair (DWORD dwGuildID, long BaseMapID, long PrivateMapID);
|
|
|
|
virtual ~CDragonLair ();
|
|
|
|
|
|
|
|
DWORD GetEstimatedTime () const;
|
|
|
|
|
|
|
|
void OnDragonDead (LPCHARACTER pDragon);
|
|
|
|
|
|
|
|
private:
|
|
|
|
DWORD StartTime_;
|
|
|
|
DWORD GuildID_;
|
|
|
|
long BaseMapIndex_;
|
|
|
|
long PrivateMapIndex_;
|
|
|
|
};
|
|
|
|
|
|
|
|
class CDragonLairManager : public singleton<CDragonLairManager>
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
CDragonLairManager ();
|
|
|
|
virtual ~CDragonLairManager ();
|
|
|
|
|
|
|
|
bool Start (long MapIndexFrom, long BaseMapIndex, DWORD GuildID);
|
|
|
|
void OnDragonDead (LPCHARACTER pDragon, DWORD KillerGuildID);
|
|
|
|
|
|
|
|
size_t GetLairCount () const { return LairMap_.size(); }
|
|
|
|
|
|
|
|
private:
|
|
|
|
boost::unordered_map<DWORD, CDragonLair*> LairMap_;
|
|
|
|
};
|
|
|
|
|