L L4D2node

CDispCollTree::Cache_EdgeCrossAxisY

0x000ce540 · 259 bytes · __thiscall

_ZN13CDispCollTree20Cache_EdgeCrossAxisYERK6VectorS2_S2_P12CDispCollTriRt

Decompiled

undefined (6 params)

/* CDispCollTree::Cache_EdgeCrossAxisY(Vector const&, Vector const&, Vector const&, CDispCollTri*,
   unsigned short&) */

undefined4 __thiscall
CDispCollTree::Cache_EdgeCrossAxisY
          (CDispCollTree *this,Vector *param_1,Vector *param_2,Vector *param_3,CDispCollTri *param_4
          ,ushort *param_5)

{
  ushort uVar1;
  float fVar2;
  float local_18;
  float local_14;
  float local_10;
  
  local_14 = 0.0;
  local_10 = *(float *)param_1;
  local_18 = -*(float *)(param_1 + 8);
  VectorNormalize((Vector *)&local_18);
  if ((local_18 != 0.0) && (local_10 != 0.0)) {
    local_14 = *(float *)(param_2 + 8) * local_10 + *(float *)param_2 * local_18;
    fVar2 = *(float *)(param_3 + 8) * local_10 + *(float *)param_3 * local_18;
    if ((0.03125 <= ABS(fVar2 - local_14)) && (local_14 < fVar2)) {
      local_18 = -local_18;
      local_14 = -local_14;
      local_10 = -local_10;
    }
    uVar1 = AddPlane(this,(Vector *)&local_18);
    *param_5 = uVar1;
    return 1;
  }
  *param_5 = 0xffff;
  return 0;
}

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)