Files
LGram16 dd97ddec92 Restructure repository to include all source folders
Move git root from Client/ to src/ to track all source code:
- Client: Game client source (moved to Client/Client/)
- Server: Game server source
- GameTools: Development tools
- CryptoSource: Encryption utilities
- database: Database scripts
- Script: Game scripts
- rylCoder_16.02.2008_src: Legacy coder tools
- GMFont, Game: Additional resources

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-29 20:17:20 +09:00

50 lines
1.1 KiB
C++

#ifndef _MONSTER_MGR_H_
#define _MONSTER_MGR_H_
#pragma once
#define g_MonsterMgr CMonsterMgr::GetInstance()
#include <Pattern/Singleton.h>
#include "MonsterStructure.h"
#include "../Character/CharacterStructure.h"
#include "../../Utility/DelimitedFile.h"
class CMonsterMgr : public CSingleton<CMonsterMgr>
{
public:
struct MonsterProtoType
{
MonsterInfo m_MonsterInfo;
CreatureStatus m_CreatureStatus;
inline bool operator < (MonsterProtoType& rhs)
{ return m_MonsterInfo.m_dwKID < rhs.m_MonsterInfo.m_dwKID; }
};
~CMonsterMgr();
bool LoadMonstersFromFile(const char* szFileName = 0);
bool LoadMonstersFromBinary(const char* szFileNameBinary = 0);
bool SaveMonstersToBinary(const char* szFileNameBinary = 0, const char* szTrashFile = 0);
void ClearProtoType();
const MonsterProtoType* GetMonsterProtoType(DWORD dwKID);
const MonsterProtoType* GetMonsterProtoType(char* szName);
private:
CMonsterMgr();
static const char* m_szMonsterScriptFileName;
static CMonsterMgr ms_this;
MonsterProtoType* m_ProtoTypeArray;
size_t m_nMonsterNum;
};
#endif