Skip to content

Commit

Permalink
move VERSION to separate redm_version file
Browse files Browse the repository at this point in the history
  • Loading branch information
SergeyShorokhov committed Sep 6, 2023
1 parent 54b5c68 commit 116eb67
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 6 deletions.
8 changes: 4 additions & 4 deletions cstrike/addons/amxmodx/scripting/ReDeathmatch.sma
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ static const g_soundEffects[][] = {
}

public plugin_init() {
register_plugin("ReDeathmatch", VERSION, "Sergey Shorokhov")
register_plugin("ReDeathmatch", REDM_VERSION, "Sergey Shorokhov")
register_dictionary("redm/redm.txt")

create_cvar("redm_version", VERSION, (FCVAR_SERVER|FCVAR_SPONLY))
create_cvar("redm_version", REDM_VERSION, (FCVAR_SERVER|FCVAR_SPONLY))

ApiInit_Forwards()

Expand Down Expand Up @@ -156,9 +156,9 @@ public ConCmd_redm_status(const player, level, cid) {
public ConCmd_redm(const player, level, cid) {
SetGlobalTransTarget(player)

console_print(player, "[Re:DM] Version `%s`", VERSION)
console_print(player, "[Re:DM] Version `%s`", REDM_VERSION)
console_print(player, "[Re:DM] https://github.com/wopox1337/ReDeathmatch")
console_print(player, "[Re:DM] Copyright (c) 2023 Sergey Shorokhov", VERSION)
console_print(player, "[Re:DM] Copyright (c) 2023 Sergey Shorokhov", REDM_VERSION)

return PLUGIN_HANDLED
}
Expand Down
2 changes: 1 addition & 1 deletion cstrike/addons/amxmodx/scripting/include/redm.inc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#define _redm_included


new const VERSION[] = "%VERSION%"
#include <redm_version>

// AMXX 1.9.0 compatibility
#if !defined MAX_MAPNAME_LENGTH
Expand Down
7 changes: 7 additions & 0 deletions cstrike/addons/amxmodx/scripting/include/redm_version.inc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#if defined _redm_version_included
#endinput
#endif
#define _redm_version_included

// redm version
new const REDM_VERSION[] = "%VERSION%"
2 changes: 1 addition & 1 deletion cstrike/addons/amxmodx/scripting/redm_spawns.sma
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public plugin_precache() {
}

public plugin_init() {
register_plugin("Spawns manager", VERSION, "Sergey Shorokhov")
register_plugin("Spawns manager", REDM_VERSION, "Sergey Shorokhov")
register_dictionary("common.txt")

rh_get_mapname(g_mapName, charsmax(g_mapName))
Expand Down

0 comments on commit 116eb67

Please sign in to comment.