L L4D2node

Motion_GetPositionInterpolator

0x00592a40 · 34 bytes · __cdecl

_Z30Motion_GetPositionInterpolatori

Decompiled

undefined (1 param)

/* Motion_GetPositionInterpolator(int) */

CPositionInterpolator_Rope * Motion_GetPositionInterpolator(int param_1)

{
  CPositionInterpolator_Rope *this;
  int iVar1;
  
  iVar1 = 0;
  if (-1 < param_1) {
    iVar1 = param_1;
  }
  switch(iVar1) {
  case 0:
    return (CPositionInterpolator_Rope *)&g_LinearInterpolator;
  case 1:
    return (CPositionInterpolator_Rope *)&g_CatmullRomInterpolator;
  default:
    this = operator_new(0x234);
    CPositionInterpolator_Rope::CPositionInterpolator_Rope(this);
    return this;
  }
}

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)