L L4D2node

MD5_PseudoRandom

0x00245e20 · 124 bytes · __cdecl

_Z16MD5_PseudoRandomj

Decompiled

undefined (1 param)

/* MD5_PseudoRandom(unsigned int) */

undefined4 MD5_PseudoRandom(uint param_1)

{
  int iVar1;
  MD5Context_t *pMVar2;
  int in_GS_OFFSET;
  uchar local_78 [6];
  undefined4 local_72;
  undefined4 local_68 [22];
  int local_10;
  
  local_10 = *(int *)(in_GS_OFFSET + 0x14);
  pMVar2 = (MD5Context_t *)local_68;
  for (iVar1 = 0x16; iVar1 != 0; iVar1 = iVar1 + -1) {
    *(undefined4 *)pMVar2 = 0;
    pMVar2 = pMVar2 + 4;
  }
  local_68[0] = 0x67452301;
  local_68[1] = 0xefcdab89;
  local_68[2] = 0x98badcfe;
  local_68[3] = 0x10325476;
  MD5Update((MD5Context_t *)local_68,(uchar *)&param_1,4);
  MD5Final(local_78,(MD5Context_t *)local_68);
  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {
    return local_72;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail();
}

SourceMod gamedata

paste into addons/sourcemod/gamedata/<your_plugin>.txt
used as the SourceMod key — change to fit your plugin's convention
SourceMod library name (server / engine / matchmaking)

Just a Signatures{} block, ready to drop into a gamedata file. Wire it up in your plugin however you like - SDKCall, DHooks, raw memory ops, or anything else.



        

        

          

Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.

Return-type handling cheatsheet (DHookReturn)