summaryrefslogtreecommitdiff
path: root/src/game
diff options
context:
space:
mode:
authorMaeJong <mewiceclair@gmail.com>2017-04-18 23:47:33 +0200
committerMaeJong <mewiceclair@gmail.com>2017-04-18 23:47:33 +0200
commitb8db90f6dbf6c894ebc1bfccbbf61fdb27025bc1 (patch)
tree5b267d39d0c4cf0ec6651384a4a5698fac9901ee /src/game
parentfb1c012ae1dfb56a1393e20571c2faf1f271a817 (diff)
Implement g_reportAdminListMinLvl
Specifies the minimum level needed for a player's name to be written in the "admins" field in reports. Defaults to 4
Diffstat (limited to 'src/game')
-rw-r--r--src/game/g_admin.c2
-rw-r--r--src/game/g_local.h1
-rw-r--r--src/game/g_main.c2
3 files changed, 4 insertions, 1 deletions
diff --git a/src/game/g_admin.c b/src/game/g_admin.c
index 365229f..c5f18d3 100644
--- a/src/game/g_admin.c
+++ b/src/game/g_admin.c
@@ -9259,7 +9259,7 @@ qboolean G_admin_report( gentity_t *ent, int skiparg )
{
vic = &g_entities[ i ];
- if( G_admin_level( vic ) >= 3 )
+ if( G_admin_level( vic ) >= g_reportAdminListMinLvl )
{
Q_strcat( admins, sizeof(admins), va( "%s^7 ", G_admin_get_adminname( vic ) ) );
}
diff --git a/src/game/g_local.h b/src/game/g_local.h
index 5835385..8edcc71 100644
--- a/src/game/g_local.h
+++ b/src/game/g_local.h
@@ -1539,6 +1539,7 @@ extern vmCvar_t g_maxReports;
extern vmCvar_t g_maxUnregReports;
extern vmCvar_t g_reportWelcomeComment;
+extern vmCvar_t g_reportAdminListMinLvl;
extern vmCvar_t g_schachtmeisterClearThreshold;
extern vmCvar_t g_schachtmeisterAutobahnThreshold;
diff --git a/src/game/g_main.c b/src/game/g_main.c
index cd53e3f..4c68925 100644
--- a/src/game/g_main.c
+++ b/src/game/g_main.c
@@ -279,6 +279,7 @@ vmCvar_t g_maxReports;
vmCvar_t g_maxUnregReports;
vmCvar_t g_reportWelcomeComment;
+vmCvar_t g_reportAdminListMinLvl;
vmCvar_t g_schachtmeisterClearThreshold;
vmCvar_t g_schachtmeisterAutobahnThreshold;
@@ -546,6 +547,7 @@ static cvarTable_t gameCvarTable[ ] =
{ &g_maxUnregReports, "g_maxUnregReports", "1", CVAR_ARCHIVE, 0, qfalse },
{ &g_reportWelcomeComment, "g_reportWelcomeComment", "", CVAR_ARCHIVE, 0, qfalse },
+ { &g_reportAdminListMinLvl, "g_reportAdminListMinLvl", "4", CVAR_ARCHIVE, 0, qfalse },
{ &g_scrimMode, "g_scrimMode", "0", CVAR_ARCHIVE, 0, qfalse },