L L4D2node

CVEngineServer::GetPVSForCluster

0x0022c090 · 97 bytes · __thiscall

_ZN14CVEngineServer16GetPVSForClusterEiiPh

Decompiled

undefined (4 params)

/* CVEngineServer::GetPVSForCluster(int, int, unsigned char*) */

int __thiscall
CVEngineServer::GetPVSForCluster(CVEngineServer *this,int param_1,int param_2,uchar *param_3)

{
  int iVar1;
  
  iVar1 = CM_NumClusters();
  iVar1 = iVar1 + 7 >> 3;
  if (param_3 != (uchar *)0x0) {
    if (param_2 < iVar1) {
      Sys_Error("GetPVSForOrigin called with inusfficient sized pvs array, need %i bytes!",iVar1);
      return iVar1;
    }
    CM_Vis(param_3,param_2,param_1,0);
  }
  return iVar1;
}

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)