Skip to content

Commit

Permalink
Added start for debug in core.
Browse files Browse the repository at this point in the history
  • Loading branch information
d3m37r4 committed Dec 8, 2023
1 parent ad9c360 commit e300e83
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
7 changes: 5 additions & 2 deletions cstrike/addons/amxmodx/scripting/regg/functions.inl
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,11 @@ bool:start(const ReGG_Mode:mode) {
.tmDelay = 3.0,
.st = WINSTATUS_DRAW,
.event = ROUND_END_DRAW,
.message = "GunGame Mod started!",
.sentence = "",
.message = "GunGame Mod started!",
.sentence = "",
.trigger = true
);
DebugMode && log_amx("GunGame Mod started!");

return true;
}
Expand All @@ -47,6 +48,8 @@ bool:finish(const killer, const victim) {
Mode = ReGG_ModeNone;
set_member_game(m_bCompleteReset, true);
rg_restart_round();
DebugMode && log_amx("GunGame Mod finished!");

return true;
}

Expand Down
5 changes: 5 additions & 0 deletions cstrike/addons/amxmodx/scripting/regg_core.sma
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ new Players[MAX_PLAYERS + 1][player_s];
new Teams[2][team_s];
new WeaponIdType:GrenadeWeapons[MAX_GRENADE_WEAPONS], GrenadeWeaponsNum;

new bool:DebugMode;

#include "regg/config.inl"
#include "regg/forwards.inl"
#include "regg/hooks.inl"
Expand All @@ -57,6 +59,9 @@ public plugin_init() {
registerForwards();
loadCfg();
loadIni();

DebugMode = bool:(plugin_flags() & AMX_FLAG_DEBUG);
DebugMode && log_amx("Debug mode is enable!");
}

public plugin_cfg() {
Expand Down

0 comments on commit e300e83

Please sign in to comment.