L L4D2node

CParticleCollection::GetControlPointAtTime

0x00bcc960 · 215 bytes · __thiscall

_ZN19CParticleCollection21GetControlPointAtTimeEifP6Vector

Decompiled

undefined (4 params)

/* CParticleCollection::GetControlPointAtTime(int, float, Vector*) */

void __thiscall
CParticleCollection::GetControlPointAtTime
          (CParticleCollection *this,int param_1,float param_2,Vector *param_3)

{
  float *pfVar1;
  undefined4 *puVar2;
  float fVar3;
  
  fVar3 = *(float *)(this + 0x34);
  if (fVar3 != 0.0) {
    if (*(int *)(this + 100) + -1 <= param_1) {
      param_1 = *(int *)(this + 100) + -1;
    }
    fVar3 = (fVar3 - (*(float *)(this + 0x24) - param_2)) / fVar3;
    pfVar1 = (float *)(param_1 * 0x5c + *(int *)(this + 0x68));
    if (fVar3 <= 0.0) {
      fVar3 = 0.0;
    }
    *(float *)param_3 = (*pfVar1 - pfVar1[3]) * fVar3 + pfVar1[3];
    *(float *)(param_3 + 4) = (pfVar1[1] - pfVar1[4]) * fVar3 + pfVar1[4];
    *(float *)(param_3 + 8) = (pfVar1[2] - pfVar1[5]) * fVar3 + pfVar1[5];
    return;
  }
  if (*(int *)(this + 100) + -1 <= param_1) {
    param_1 = *(int *)(this + 100) + -1;
  }
  puVar2 = (undefined4 *)(param_1 * 0x5c + *(int *)(this + 0x68));
  *(undefined4 *)param_3 = *puVar2;
  *(undefined4 *)(param_3 + 4) = puVar2[1];
  *(undefined4 *)(param_3 + 8) = puVar2[2];
  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)