CTerrorGameRules::CreateStandardEntities
0x00502830 · 453 bytes · __cdecl
_ZN16CTerrorGameRules22CreateStandardEntitiesEv
Decompiled
undefined (0 params)
/* CTerrorGameRules::CreateStandardEntities() */
void CTerrorGameRules::CreateStandardEntities(void)
{
CBaseIssue *pCVar1;
CBaseEntity *pCVar2;
g_pPlayerResource =
CBaseEntity::Create("terror_player_manager",(Vector *)&vec3_origin,(QAngle *)&vec3_angle,
(CBaseEntity *)0x0);
CBaseEntity::Create("vote_controller",(Vector *)&vec3_origin,(QAngle *)&vec3_angle,
(CBaseEntity *)0x0);
pCVar1 = ::operator_new(0x84);
/* try { // try from 0050289e to 005028a2 has its CatchHandler @ 00502a22 */
CBaseIssue::CBaseIssue(pCVar1,"ChangeDifficulty");
*(undefined ***)pCVar1 = &PTR__CChangeDifficultyIssue_00d1cfa8;
pCVar1 = ::operator_new(0x84);
/* try { // try from 005028c2 to 005028c6 has its CatchHandler @ 00502a16 */
CBaseIssue::CBaseIssue(pCVar1,"RestartGame");
*(undefined ***)pCVar1 = &PTR__CRestartGameIssue_00d1d008;
pCVar1 = ::operator_new(0x108);
/* try { // try from 005028e6 to 005028ea has its CatchHandler @ 00502a14 */
CBaseIssue::CBaseIssue(pCVar1,"Kick");
*(undefined ***)pCVar1 = &PTR__CKickIssue_00d1d0c8;
pCVar1[0x84] = (CBaseIssue)0x0;
pCVar1[0x85] = (CBaseIssue)0x0;
pCVar1 = ::operator_new(0x84);
/* try { // try from 00502918 to 0050291c has its CatchHandler @ 00502a12 */
CBaseIssue::CBaseIssue(pCVar1,"ChangeMission");
*(undefined ***)pCVar1 = &PTR__CChangeMissionIssue_00d1d128;
pCVar1 = ::operator_new(0x84);
/* try { // try from 0050293c to 00502940 has its CatchHandler @ 00502a0f */
CBaseIssue::CBaseIssue(pCVar1,"ReturnToLobby");
*(undefined ***)pCVar1 = &PTR__CReturnToLobbyIssue_00d1d068;
pCVar1 = ::operator_new(0x84);
/* try { // try from 00502960 to 00502964 has its CatchHandler @ 00502a0d */
CBaseIssue::CBaseIssue(pCVar1,"ChangeChapter");
*(undefined ***)pCVar1 = &PTR__CChangeChapterIssue_00d1d188;
pCVar1 = ::operator_new(0x84);
/* try { // try from 00502984 to 00502988 has its CatchHandler @ 005029fb */
CBaseIssue::CBaseIssue(pCVar1,"ChangeAllTalk");
*(undefined ***)pCVar1 = &PTR__CChangeAllTalkIssue_00d1d1e8;
if (*(int *)(gpGlobals + 0x48) != 0) {
return;
}
pCVar2 = (CBaseEntity *)
CGlobalEntityList::FindEntityByClassname
((CGlobalEntityList *)gEntList,(CBaseEntity *)0x0,"terror_gamerules");
if (pCVar2 != (CBaseEntity *)0x0) {
UTIL_RemoveImmediate(pCVar2);
}
CBaseEntity::Create("terror_gamerules",(Vector *)&vec3_origin,(QAngle *)&vec3_angle,
(CBaseEntity *)0x0);
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.