CDmxSerializerKeyValues2::EatWhitespacesAndComments
0x00bec630 · 263 bytes · __thiscall
_ZN24CDmxSerializerKeyValues225EatWhitespacesAndCommentsER10CUtlBuffer
Decompiled
undefined (2 params)
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* CDmxSerializerKeyValues2::EatWhitespacesAndComments(CUtlBuffer&) */
void __thiscall
CDmxSerializerKeyValues2::EatWhitespacesAndComments
(CDmxSerializerKeyValues2 *this,CUtlBuffer *param_1)
{
char *pcVar1;
uint uVar2;
int iVar3;
int iVar4;
iVar3 = 0;
iVar4 = *(int *)(param_1 + 0x1c) - *(int *)(param_1 + 0xc);
if (iVar4 < 1) {
LAB_00bec727:
CUtlBuffer::SeekGet(param_1,1,iVar3);
return;
}
LAB_00bec650:
do {
pcVar1 = (char *)CUtlBuffer::PeekGet(param_1,1,iVar3);
if (pcVar1 != (char *)0x0) {
uVar2 = (int)*pcVar1 - 9;
if ((uVar2 < 0x18) && ((1 << ((byte)uVar2 & 0x1f) & 0x80001fU) != 0)) {
if (*pcVar1 == '\n') {
_DAT_0105b764 = _DAT_0105b764 + 1;
}
iVar3 = iVar3 + 1;
if (iVar3 < iVar4) goto LAB_00bec650;
}
}
pcVar1 = (char *)CUtlBuffer::PeekGet(param_1,2,iVar3);
if ((((pcVar1 == (char *)0x0) || (iVar4 <= iVar3)) || (*pcVar1 != '/')) || (pcVar1[1] != '/'))
goto LAB_00bec727;
iVar3 = iVar3 + 2;
while ((pcVar1 = (char *)CUtlBuffer::PeekGet(param_1,1,iVar3), pcVar1 != (char *)0x0 &&
(*pcVar1 != '\n'))) {
iVar3 = iVar3 + 1;
if (iVar4 <= iVar3) {
_DAT_0105b764 = _DAT_0105b764 + 1;
goto LAB_00bec727;
}
}
_DAT_0105b764 = _DAT_0105b764 + 1;
if (iVar4 <= iVar3) goto LAB_00bec727;
} while( true );
}
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.