Repository navigation
Expand file tree
/
Copy pathstdafx.h
More file actions
106 lines (84 loc) · 1.86 KB
/
Copy pathstdafx.h
File metadata and controls
106 lines (84 loc) · 1.86 KB
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
// stdafx.h : include file for standard system include files,
// or project specific include files that are used frequently, but
// are changed infrequently
//
#pragma once
#include "targetver.h"
#define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers
// Windows Library Files:
#pragma comment(lib, "ws2_32.lib")
#pragma comment(lib, "Winmm.lib")
// Windows Header Files:
#include <windows.h>
#include <Mmsystem.h>
#include <string>
#include <vector>
#include <sstream>
#include <fstream>
#include <iostream>
#include <map>
#include <set>
#include <unordered_map>
#include <algorithm>
#include <functional>
#include <Psapi.h>
#include <MinHook.h>
#include <timeapi.h>
#include <time.h>
// Additional Header Files:
#include "Log.h"
#include "Memory.h"
#include "types.h"
#include "enums.h"
#include "InputHook.h"
#include "keyboard.h"
#include "CrossMapping.h"
#include "NativeInvoker.h"
#include "nativeCaller.h"
#include "natives.h"
#include "Hooking.h"
// Menu Files:
#include "GUI.h"
#include "menu.h"
#include "types.h"
#include "Functions.h"
#include <locale>
#include <codecvt>
#include <stdio.h>
#include "Auth/Networking/sha512.hh"
#include "Auth/Networking/Web2.0.h"
extern int selectedPlayer;
class globalHandle
{
private:
void* _handle;
public:
globalHandle(int index)
: _handle(&Hooking::getGlobalPtr()[index >> 18 & 0x3F][index & 0x3FFFF])
{ }
globalHandle(void* p)
: _handle(p)
{ }
globalHandle(const globalHandle& copy)
: _handle(copy._handle)
{ }
globalHandle At(int index)
{
return globalHandle(reinterpret_cast<void**>(this->_handle) + (index));
}
globalHandle At(int index, int size)
{
// Position 0 = Array Size
return this->At(1 + (index * size));
}
template <typename T>
T* Get()
{
return reinterpret_cast<T*>(this->_handle);
}
template <typename T>
T& As()
{
return *this->Get<T>();
}
};