DispInfo_CreateFromMapDisp
0x0013a080 · 337 bytes · __cdecl
_Z26DispInfo_CreateFromMapDispP7model_tiPK11ddispinfo_tP13CCoreDispInfoPK9CDispVertPK8CDispTriPK25MaterialSystem_SortInfo_tb
Decompiled
undefined (8 params)
/* DispInfo_CreateFromMapDisp(model_t*, int, ddispinfo_t const*, CCoreDispInfo*, CDispVert const*,
CDispTri const*, MaterialSystem_SortInfo_t const*, bool) */
undefined4
DispInfo_CreateFromMapDisp
(model_t *param_1,int param_2,ddispinfo_t *param_3,CCoreDispInfo *param_4,
CDispVert *param_5,CDispTri *param_6,MaterialSystem_SortInfo_t *param_7,bool param_8)
{
char cVar1;
CDispInfo *this;
int iVar2;
CCoreDispInfo *pCVar3;
undefined4 uVar4;
msurface2_t *extraout_ECX;
this = (CDispInfo *)DispInfo_IndexArray(*(void **)(*(int *)(param_1 + 0x134) + 0x6c),param_2);
*(undefined4 *)(param_4 + 0x1ac) = *(undefined4 *)param_3;
*(undefined4 *)(param_4 + 0x1b0) = *(undefined4 *)(param_3 + 4);
*(undefined4 *)(param_4 + 0x1b4) = *(undefined4 *)(param_3 + 8);
CCoreDispInfo::InitDispInfo
(param_4,*(int *)(param_3 + 0x14),*(int *)(param_3 + 0x18),*(float *)(param_3 + 0x1c),
param_5,param_6);
CCoreDispSurface::SetNeighborData
((CCoreDispSurface *)(param_4 + 0x10),(CDispNeighbor *)(param_3 + 0x30),
(CDispCornerNeighbors *)(param_3 + 0x60));
iVar2 = 0;
do {
*(undefined4 *)(param_4 + iVar2 * 4 + 0x1dc) = *(undefined4 *)(param_3 + iVar2 * 4 + 0x88);
iVar2 = iVar2 + 1;
} while (iVar2 != 10);
pCVar3 = (CCoreDispInfo *)(**(code **)(*(int *)this + 0x18))(this);
BuildDispSurfInit((model_t *)param_4,pCVar3,extraout_ECX);
cVar1 = CCoreDispInfo::Create(param_4);
if (cVar1 != '\0') {
*(undefined4 *)(this + 0x170) = *(undefined4 *)(param_4 + 0x1a8);
*(undefined2 *)(this + 0x262) = (undefined2)param_2;
CDispInfo::CopyMapDispData(this,param_3);
uVar4 = CDispInfo::CopyCoreDispData(this,param_1,param_7,param_4,param_8);
if ((char)uVar4 != '\0') {
CDispInfo::InitializeActiveVerts(this);
*(undefined4 *)(this + 0x238) = *(undefined4 *)(param_3 + 0x2c);
return uVar4;
}
}
return 0;
}
SourceMod gamedata
paste intoaddons/sourcemod/gamedata/<your_plugin>.txt
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.
Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.