We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2268b5d commit a222b63Copy full SHA for a222b63
src/game/server/client.cpp
@@ -843,6 +843,28 @@ void StartFrame(void)
843
g_ulFrameCount++;
844
}
845
846
+#ifdef PLATFORM_WINDOWS
847
+
848
+// Signature for g_pGameRules in AMXX
849
+// Exported so the function is not removed by the linker
850
+DLL_EXPORT __declspec(naked) void BHL_Signature_g_pGameRules()
851
+{
852
+ // AMXX signature
853
+ // "windows" "\x8B\x2A\x2A\x2A\x2A\x2A\x85\x2A\x74\x2A\x8B\x2A\xFF\x2A\x2A\xA1" // StartFrame()
854
+ __asm
855
+ {
856
+ mov ecx, g_pGameRules // 8B xx xx xx xx xx
857
+ test ecx,ecx // 85 xx
858
+ jz short jump_label // 74 xx
859
+ mov eax, [ecx] // 8B xx
860
+ call dword ptr [eax+4] // FF xx xx
861
+ jump_label:
862
+ _emit 0xA1 // A1
863
+ }
864
+}
865
866
+#endif
867
868
void ClientPrecache(void)
869
{
870
// setup precaches always needed
0 commit comments