feat(object): implement ClntObjMgrGetMapID

This commit is contained in:
fallenoak 2026-01-05 22:27:41 -06:00
parent c6eef57289
commit 35787c4ac8
No known key found for this signature in database
GPG Key ID: 7628F8E61AEA070D
3 changed files with 30 additions and 4 deletions

View File

@ -0,0 +1,16 @@
#ifndef OBJECT_CLIENT_CLNT_OBJ_MGR_HPP
#define OBJECT_CLIENT_CLNT_OBJ_MGR_HPP
#include <cstdint>
class ClientConnection;
class ClntObjMgr {
public:
// Member variables
uint64_t m_activePlayer = 0;
uint32_t m_mapID = 0;
ClientConnection* m_net = nullptr;
};
#endif

View File

@ -1,6 +1,16 @@
#include "object/client/ObjMgr.hpp"
#include "object/client/ClntObjMgr.hpp"
#if defined(WHOA_SYSTEM_WIN)
static thread_local ClntObjMgr* s_curMgr;
#else
static ClntObjMgr* s_curMgr;
#endif
uint32_t ClntObjMgrGetMapID() {
// TODO
return -1;
if (!s_curMgr) {
return 0;
}
return s_curMgr->m_mapID;
}

View File

@ -1,5 +1,5 @@
#ifndef OBJECT_CLIENT_CLIENT_OBJ_MGR_HPP
#define OBJECT_CLIENT_CLIENT_OBJ_MGR_HPP
#ifndef OBJECT_CLIENT_OBJ_MGR_HPP
#define OBJECT_CLIENT_OBJ_MGR_HPP
#include <cstdint>