noclip
0x00644030 · 142 bytes · __cdecl
_ZL6noclipRK8CCommand
Decompiled
undefined (1 param)
/* noclip(CCommand const&) */
void noclip(CCommand *param_1)
{
char cVar1;
CBasePlayer *pCVar2;
int iVar3;
if (((*(int *)(*(int *)(sv_cheats + 0x1c) + 0x30) != 0) &&
(pCVar2 = (CBasePlayer *)UTIL_GetCommandClient(), pCVar2 != (CBasePlayer *)0x0)) &&
(cVar1 = (**(code **)(*(int *)pCVar2 + 0x16c))(pCVar2), cVar1 != '\0')) {
if (*(int *)param_1 < 2) {
if (pCVar2[0x186] != (CBasePlayer)0x8) {
LAB_006440ac:
EnableNoClip(pCVar2);
return;
}
LAB_00644095:
DisableNoClip(pCVar2);
return;
}
iVar3 = V_atoi(*(char **)(param_1 + 0x40c));
if (iVar3 == 0) {
if (pCVar2[0x186] == (CBasePlayer)0x8) goto LAB_00644095;
}
else if (pCVar2[0x186] != (CBasePlayer)0x8) goto LAB_006440ac;
}
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.