The new ILuaShared

So basically, quite a few updates ago, there was an interfaced named ILuaShared001. When Azu joined the GMod team, he removed the exports of ILuaShared, causing it to be locked away inside code. Recently, in my addon “Addonissimo”, I rediscovered a useful function which found ILuaShared again, but it had changed a lot since the last time Azu reverse engineered it. Basically, I took a few hours and reverse engineered it myself, and located a few functions new functions and found the old relocated functions. So, here it is, if anyone in the future would like to use it:

Look below.

Here is the actual structure if you want to tidy it up:

1	CLuaShared::Init(void * (*)(char  const*,int *),bool,CSteamAPIContext *)
2	CLuaShared::LoadCache(void)
3	CLuaShared::SaveCache(void)
4	CLuaShared::Shutdown(void)
5	CLuaShared::DumpStats(void)
6	CLuaShared::CreateLuaInterface(ILuaCallback *)
7	CLuaShared::CloseLuaInterface(ILuaInterface *)
8	CLuaShared::GetFile(char  const*,char  const*,bool,bool,bool *)
9	CLuaShared::FileExists(char  const*,char  const*,bool,bool,bool *)
10	CLuaShared::SetTranslateHook(ILuaTranslate *)
11	CLuaShared::MountContent(void)
12	CLuaShared::MountAddons(void)
13	CLuaShared::MountGamemodes(void)
14	CLuaShared::MountLua(char  const*,bool)
15	CLuaShared::MountLuaAdd(char  const*,char  const*)
16	CLuaShared::UnMountLua(char  const*)
17	CLuaShared::GetAddonList(void)
18	CLuaShared::GetGamemodeList(void)
19	CLuaShared::GetContentList(void)
20	CLuaShared::LZMACompress(unsigned char *,int,EVLZMAError *,int *)
21	CLuaShared::LZMADecompress(unsigned char *,int,unsigned char **)
22	CLuaShared::GetInterfaceByState(lua_State *)
23	CLuaShared::SetDepotMountable(char  const*,bool)
24	CLuaShared::AddInterface(ILuaInterface *)
25	CLuaShared::RemoveInterface(ILuaInterface *)

So much for that work… :sigh:


Anyone know the return types on these?

Which ones do you want to know?

The interface and callback methods look interesting, or any for that matter. I’m not sure how to figure them out on my own =[