L L4D2node

GetEffectNameFromIndex

0x006ca410 · 59 bytes · __cdecl

_Z22GetEffectNameFromIndexi

Decompiled

undefined (1 param)

/* GetEffectNameFromIndex(int) */

char * GetEffectNameFromIndex(int param_1)

{
  int iVar1;
  char *pcVar2;
  
  iVar1 = (**(code **)(*g_pStringTableEffectDispatch + 0x14))(g_pStringTableEffectDispatch);
  pcVar2 = "error";
  if (param_1 < iVar1) {
    pcVar2 = (char *)(**(code **)(*g_pStringTableEffectDispatch + 0x28))
                               (g_pStringTableEffectDispatch,param_1);
  }
  return pcVar2;
}

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)