-
Notifications
You must be signed in to change notification settings - Fork 24
Expand file tree
/
Copy pathr.lua.h
More file actions
105 lines (91 loc) · 3.58 KB
/
r.lua.h
File metadata and controls
105 lines (91 loc) · 3.58 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
#include <windef.h>
#include <iostream>
#include <vector>
typedef void(*Lua_pushstring)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_setfield)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_createtable)(/*SNIPPED FOR SECURITY*/);
typedef int(*Lua_error)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_pushcclosure)(/*SNIPPED FOR SECURITY*/);
typedef int(*Lua_pcall)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_createtable)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_pushlightuserdata)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_getfield)(/*SNIPPED FOR SECURITY*/);
typedef void*(*Lua_newuserdata)(/*SNIPPED FOR SECURITY*/);
typedef int(*Lua_setmetatable)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_pushnumber)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_settop)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_pushboolean)(/*SNIPPED FOR SECURITY*/);
typedef void(*Lua_pushinteger)(/*SNIPPED FOR SECURITY*/);
typedef int(*LSetProperty)(DWORD luaState);
//typedef int(*LGetProperty)(DWORD luaState);
typedef struct Vector3 { /*SNIPPED FOR SECURITY*/ };
typedef struct CFrame
{
/*SNIPPED FOR SECURITY*/
};
typedef struct InstanceTable {
/*SNIPPED FOR SECURITY*/
};
typedef struct ScanResults {
DWORD failList[13];
DWORD failCount;
};
//typedef int(__thiscall *SetMinutesAfterMidnight)(/*SNIPPED FOR SECURITY*/);
typedef int(__thiscall *SetCFrame)(/*SNIPPED FOR SECURITY*/);
typedef CFrame*(__thiscall *GetCFrame)(/*SNIPPED FOR SECURITY*/);
typedef int(__thiscall *PlaySoundInstance)(/*SNIPPED FOR SECURITY*/);
typedef int(__thiscall *StopSoundInstance)(/*SNIPPED FOR SECURITY*/);
class RLua {
DWORD L;
LSetProperty lSetProperty;
//LGetProperty lGetProperty;
ScanResults results;
InstanceTable getInstanceTable(DWORD instance, DWORD offset);
SetCFrame setCFrame;
GetCFrame getCFrame;
public:
//RLua(const DWORD lcvPtr);
void initiate(const DWORD lcvPtr);
DWORD getLuaState();
ScanResults getInitResults();
void setProperty(DWORD instance, const char* propName, const char* valueType, void* value);
Lua_pushstring pushstring;
Lua_setfield setfield;
Lua_createtable createtable;
Lua_error error;
Lua_pushcclosure pushcclosure;
Lua_pcall pcall;
Lua_pushlightuserdata pushlightuserdata;
Lua_pushnumber pushnumber;
Lua_getfield getfield;
Lua_newuserdata newuserdata;
Lua_setmetatable setmetatable;
Lua_settop settop;
Lua_pushboolean pushboolean;
Lua_pushinteger pushinteger;
std::vector<DWORD> getChildren(DWORD instance);
std::vector<DWORD> getRecursiveChildren(DWORD instance);
DWORD getChildByName(DWORD instance, const char* name);
DWORD getInstanceInHierarchy(DWORD gameInstance, char** names, DWORD size);
std::vector<DWORD> getPlayers(DWORD gameInst);
DWORD getPlayerByName(DWORD gameInstance, const char* name);
DWORD getCharacterFromPlayer(DWORD player);
//DWORD createInstance(char *instanceName, DWORD parent);
void destroyInstance(DWORD instance); // naked
void setObjectCFrame(DWORD instance, float x, float y, float z);
void setObjectCFrame(DWORD instance, CFrame* cfStruct);
CFrame* getObjectCFrame(DWORD instance);
DWORD getLocalPlayer(DWORD gameInstance);
void unanchorChildren(DWORD instance);
void unlockChildren(DWORD instance);
DWORD clearInstanceByName(DWORD instance, const char* name);
DWORD clearInstanceByClass(DWORD instance, const char* cname);
const char* getName(DWORD instance);
const char* getClassName(DWORD instance);
//SetMinutesAfterMidnight setMinutesAfterMidnight;
PlaySoundInstance playSoundInstance;
StopSoundInstance stopSoundInstance;
DWORD setInstanceParent;
DWORD getInstanceIDFromName;
};
DWORD createInstance(RLua& rLua, char *instanceName, DWORD parent);