L L4D2node

CNavMesh::AddWalkableSeeds

0x0072c170 · 267 bytes · __thiscall

_ZN8CNavMesh16AddWalkableSeedsEv

Decompiled

undefined (1 param)

/* CNavMesh::AddWalkableSeeds() */

void __thiscall CNavMesh::AddWalkableSeeds(CNavMesh *this)

{
  char cVar1;
  char *pcVar2;
  CBaseEntity *this_00;
  longdouble lVar3;
  float local_34;
  float local_30;
  undefined4 local_2c;
  Vector local_28 [24];
  
  pcVar2 = "info_player_start";
  if (*(char **)(this + 0x554) != (char *)0x0) {
    pcVar2 = *(char **)(this + 0x554);
  }
  this_00 = (CBaseEntity *)
            CGlobalEntityList::FindEntityByClassname
                      ((CGlobalEntityList *)gEntList,(CBaseEntity *)0x0,pcVar2);
  if (this_00 != (CBaseEntity *)0x0) {
    if (((byte)this_00[0x14d] & 8) != 0) {
      CBaseEntity::CalcAbsolutePosition(this_00);
    }
    local_34 = *(float *)(this_00 + 0x2e0);
    local_30 = *(float *)(this_00 + 0x2e4);
    local_2c = *(undefined4 *)(this_00 + 0x2e8);
    lVar3 = (longdouble)SnapToGrid(TheNavMesh,local_34,false);
    local_34 = (float)lVar3;
    lVar3 = (longdouble)SnapToGrid(TheNavMesh,local_30,false);
    local_30 = (float)lVar3;
    cVar1 = FindGroundForNode(this,(Vector *)&local_34,local_28);
    if (cVar1 != '\0') {
      AddWalkableSeed(this,(Vector *)&local_34,local_28);
      return;
    }
  }
  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)