-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathprop_manager.hpp
42 lines (32 loc) · 963 Bytes
/
prop_manager.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#pragma once
#include "sdk.hpp"
#include <ostream>
#include <iostream>
#include <string>
#include <future>
#include <fstream>
#include <sstream>
#include <unordered_map>
#include <string>
namespace Engine
{
class PropManager : public Core::Singleton<PropManager>
{
public:
~PropManager();
public:
bool Create(IBaseClientDLL* client);
void Destroy();
int GetOffset(const std::string& table_name, const std::string& prop_name);
RecvVarProxyFn Hook(const RecvVarProxyFn hooked, const std::string& table_name, const std::string& prop_name);
void DumpProps();
private:
int GetProp(const std::string& table_name, const std::string& prop_name, RecvProp** out_prop = nullptr);
int GetProp(RecvTable* table, const std::string& prop_name, RecvProp** out_prop = nullptr);
RecvTable* GetTable(const std::string& name);
void DumpTable(RecvTable* table, int depth);
private:
std::vector<RecvTable*> m_pTables;
std::ofstream m_file;
};
}