CBaseServerVehicle::NPC_GetAvailableSeat
0x00b3b6d0 · 109 bytes · __thiscall
_ZN18CBaseServerVehicle20NPC_GetAvailableSeatEP20CBaseCombatCharacter8string_t18VehicleSeatQuery_e
Decompiled
undefined (4 params)
/* CBaseServerVehicle::NPC_GetAvailableSeat(CBaseCombatCharacter*, string_t, VehicleSeatQuery_e) */
undefined4 __thiscall
CBaseServerVehicle::NPC_GetAvailableSeat
(CBaseServerVehicle *param_1,CBaseCombatCharacter *param_2,undefined4 param_3,int param_4)
{
int iVar1;
undefined4 uVar2;
if (param_1[0x68] == (CBaseServerVehicle)0x0) {
(**(code **)(*(int *)param_1 + 0xf4))(param_1);
param_1[0x68] = (CBaseServerVehicle)0x1;
}
iVar1 = FindRoleIndexByName(param_1,param_3);
if (((-1 < iVar1) && (iVar1 < *(int *)(param_1 + 0x24))) && (param_4 == 0)) {
uVar2 = NPC_GetAvailableSeat_Any(param_1,param_2,iVar1);
return uVar2;
}
return 0xffffffff;
}
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.