L L4D2node

CModelLoader::Studio_ReloadModels

0x00194550 · 273 bytes · __cdecl

_ZN12CModelLoader19Studio_ReloadModelsEN12IModelLoader12ReloadType_tE

Decompiled

undefined (1 param)

/* CModelLoader::Studio_ReloadModels(IModelLoader::ReloadType_t) */

void CModelLoader::Studio_ReloadModels(int *param_1)

{
  int *piVar1;
  char cVar2;
  uint uVar3;
  int iVar4;
  int iVar5;
  
  if (serverGameDLL != (int *)0x0) {
    (**(code **)(*serverGameDLL + 0x88))(serverGameDLL);
  }
  iVar5 = 0;
  (**(code **)(*(int *)modelrender + 0x28))(modelrender);
  (**(code **)(*(int *)modelrender + 0x38))(modelrender);
  (**(code **)(*g_pMDLCache + 0x58))(g_pMDLCache,0x7fffff7b);
  uVar3 = (uint)*(ushort *)((int)param_1 + 0x16);
  if (uVar3 != 0) {
    do {
      while( true ) {
        iVar4 = *(int *)(iVar5 * 0x10 + param_1[2] + 0xc);
        cVar2 = (**(code **)(*param_1 + 0x50))(param_1,iVar4);
        piVar1 = g_pMDLCache;
        if ((cVar2 == '\0') || (*(int *)(iVar4 + 0x110) != 3)) break;
        (**(code **)(*g_pMDLCache + 0x68))(g_pMDLCache);
                    /* try { // try from 0019460f to 00194642 has its CatchHandler @ 00194668 */
        (**(code **)(*g_pMDLCache + 0x28))(g_pMDLCache,*(undefined2 *)(iVar4 + 0x134));
        iVar4 = (**(code **)(*g_pMDLCache + 0x30))(g_pMDLCache,*(undefined2 *)(iVar4 + 0x134));
        if (iVar4 != 0) {
          (**(code **)(*physcollision + 0xe0))(physcollision,iVar4);
        }
        iVar5 = iVar5 + 1;
        (**(code **)(*piVar1 + 0x6c))(piVar1);
        if ((int)uVar3 <= iVar5) {
          return;
        }
      }
      iVar5 = iVar5 + 1;
    } while (iVar5 < (int)uVar3);
  }
  return;
}

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)