mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-09 05:41:46 +08:00
3rdparty: add MultiEmulator by 2010kohtep
* patched to be portable, turned into a static library * integrated to the engine
This commit is contained in:
13
3rdparty/MultiEmulator/src/OldRevEmu.cpp
vendored
Normal file
13
3rdparty/MultiEmulator/src/OldRevEmu.cpp
vendored
Normal file
@@ -0,0 +1,13 @@
|
||||
#include "multi_emulator.h"
|
||||
|
||||
int GenerateOldRevEmu(void* pDest, int nSteamID)
|
||||
{
|
||||
auto pTicket = (int*)pDest;
|
||||
auto pbTicket = (unsigned char*)pDest;
|
||||
|
||||
pTicket[0] = 0xFFFF; // +0, header
|
||||
pTicket[1] = (nSteamID ^ 0xC9710266) << 1; // +4, SteamId
|
||||
*(short *)&pbTicket[8] = 0; // +8, unknown, in original emulator must be 0
|
||||
|
||||
return 10;
|
||||
}
|
||||
Reference in New Issue
Block a user