L L4D2node

nav_trouble_report_invalid

0x0098fd70 · 304 bytes · __cdecl

_ZL26nav_trouble_report_invalidRK8CCommand

Decompiled

undefined (1 param)

/* nav_trouble_report_invalid(CCommand const&) */

void nav_trouble_report_invalid(CCommand *param_1)

{
  int iVar1;
  undefined4 uVar2;
  NavAreaCollector local_24 [4];
  int local_20 [6];
  
  iVar1 = CNavMesh::GetMarkedArea(TheNavMesh);
  if (iVar1 == 0) {
    s_testNavID = 0;
  }
  else {
    s_testNavID = *(undefined4 *)(iVar1 + 0x8c);
  }
  local_20[0] = 0;
  local_20[1] = 0;
  local_20[2] = 0;
  local_20[3] = 0;
  local_20[4] = 0;
  local_24[0] = (NavAreaCollector)0x1;
                    /* try { // try from 0098fdc1 to 0098fe93 has its CatchHandler @ 0098fea5 */
  SelectOrphanAreas(local_24);
  SelectOrphanBattlefieldAreas(local_24);
  SelectOrphanFinaleAreas(local_24);
  SelectOrphanCheckpointAreas(local_24);
  SelectClimbUpFromStairs(local_24);
  s_testNavID = 0;
  CNavMesh::ClearSelectedSet(TheNavMesh);
  iVar1 = 0;
  if (0 < local_20[3]) {
    do {
      CNavMesh::AddToSelectedSet(TheNavMesh,*(CNavArea **)(local_20[0] + iVar1 * 4));
      iVar1 = iVar1 + 1;
    } while (iVar1 < local_20[3]);
  }
  iVar1 = CNavMesh::GetSelecteSetSize(TheNavMesh);
  if (iVar1 == 0) {
    Msg("No trouble areas selected\n");
  }
  else {
    uVar2 = CNavMesh::GetSelecteSetSize(TheNavMesh);
    Warning("Selected %d trouble areas\n",uVar2);
  }
  local_20[3] = 0;
  CUtlMemory<CNavArea*,int>::Purge((CUtlMemory<CNavArea*,int> *)local_20);
  local_20[4] = local_20[0];
  CUtlMemory<CNavArea*,int>::Purge((CUtlMemory<CNavArea*,int> *)local_20);
  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)