CModelRender::ForcedMaterialOverride
0x00185c20 · 218 bytes · __thiscall
_ZN12CModelRender22ForcedMaterialOverrideEP9IMaterial14OverrideType_t
Decompiled
undefined (3 params)
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* CModelRender::ForcedMaterialOverride(IMaterial*, OverrideType_t) */
void __thiscall
CModelRender::ForcedMaterialOverride(undefined4 this,undefined4 param_1,undefined4 param_3)
{
undefined4 uVar1;
undefined4 uVar2;
int iVar3;
undefined4 local_24;
undefined4 local_20;
local_24 = 0;
local_20 = 0;
if (_g_Telemetry == 0) {
iVar3 = 0;
}
else {
(**(code **)(_g_Telemetry + 0x50))
(_g_Telemetry,&local_24,0,0,0,0,"/data/src/engine/./l_studio.cpp",0x8ec,
&ForcedMaterialOverride(IMaterial*,OverrideType_t)::tm_fmt,&DAT_002c48a3,
"ForcedMaterialOverride");
iVar3 = _g_Telemetry;
}
uVar2 = local_20;
uVar1 = local_24;
/* try { // try from 00185cbd to 00185cbf has its CatchHandler @ 00185d00 */
(**(code **)(*g_pStudioRender + 0x74))(g_pStudioRender,param_1,param_3);
if (iVar3 != 0) {
(**(code **)(iVar3 + 0x54))(iVar3,uVar1,uVar2,0,0,0);
}
return;
}
SourceMod gamedata
paste intoaddons/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.
Signatures + Functions block. The plugin uses
DHookCreateFromConf - DHooks reads return type, this-type,
calling convention, and argument types straight from the gamedata. Less
boilerplate in the plugin, types travel with the gamedata.
Gamedata KeyValues
DHooks plugin example
Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.