diff --git a/saco/net/netrpc.cpp b/saco/net/netrpc.cpp index faf2cbe..fc43783 100644 --- a/saco/net/netrpc.cpp +++ b/saco/net/netrpc.cpp @@ -21,6 +21,22 @@ public: extern CDownloadListDispatch *dword_1026EB98; +// dispatch helpers invoked on the editor globals (thiscall); only the touched fields are known +class CEditDispatch +{ +public: + + DWORD field_0; + char _gap4[0x7C]; + DWORD field_80; + + void FUNC_1006DB80(BOOL bEnable); // .text:1006DB80 + void FUNC_10072BC0(BOOL bEnable); // .text:10072BC0 +}; + +extern int dword_1026EB60; +extern int dword_1026EB64; + // MATCH BYTE Checksum(BYTE *pData, WORD wLen) { @@ -553,7 +569,19 @@ void RequestSpawn(RPCParameters *rpcParams) void EditAttachedObject(RPCParameters *rpcParams) {} void EditObject(RPCParameters *rpcParams) {} void SelectObject(RPCParameters *rpcParams) {} -void Unk1C(RPCParameters *rpcParams) {} +void Unk1C(RPCParameters *rpcParams) +{ + PCHAR Data = reinterpret_cast(rpcParams->input); + int iBitLength = rpcParams->numberOfBitsOfData; + + RakNet::BitStream bsData(Data,(iBitLength/8)+1,false); + + if(dword_1026EB60 && ((CEditDispatch *)dword_1026EB60)->field_80) + ((CEditDispatch *)dword_1026EB60)->FUNC_10072BC0(FALSE); + + if(dword_1026EB64 && ((CEditDispatch *)dword_1026EB64)->field_0) + ((CEditDispatch *)dword_1026EB64)->FUNC_1006DB80(FALSE); +} void UnkAA(RPCParameters *rpcParams) { PCHAR Data = reinterpret_cast(rpcParams->input);