From 87eecb857556886f5c35851cb349d58b5436665e Mon Sep 17 00:00:00 2001 From: div0 Date: Mon, 15 Dec 2008 13:51:05 +0000 Subject: [PATCH] remove some more cvars as private git-svn-id: svn://svn.icculus.org/nexuiz/trunk@5220 f962a42d-fe04-0410-a3ab-8c8b0445ebaa --- data/cvars.txt | 9 --------- data/cvars.txt.pl | 29 ++++++++++++++++++++++++++--- 2 files changed, 26 insertions(+), 12 deletions(-) diff --git a/data/cvars.txt b/data/cvars.txt index abb589442..b60ebd3fd 100644 --- a/data/cvars.txt +++ b/data/cvars.txt @@ -422,8 +422,6 @@ "g_balance_uzi_sustained_refire" "TODO: describe me" "g_balance_uzi_sustained_spread" "TODO: describe me" "g_balance_weaponswitchdelay" "TODO: describe me" -"g_ban_default_bantime" "TODO: describe me" -"g_ban_default_masksize" "TODO: describe me" "g_bugrigs" "TODO: describe me" "g_bugrigs_accel" "TODO: describe me" "g_bugrigs_air_steering" "TODO: describe me" @@ -442,13 +440,6 @@ "g_casings" "TODO: describe me" "g_changeteam_banned" "TODO: describe me" "g_changeteam_fragtransfer" "TODO: describe me" -"g_chat_flood_burst" "TODO: describe me" -"g_chat_flood_burst_team" "TODO: describe me" -"g_chat_flood_lmax" "TODO: describe me" -"g_chat_flood_lmax_team" "TODO: describe me" -"g_chat_flood_notify_flooder" "TODO: describe me" -"g_chat_flood_spl" "TODO: describe me" -"g_chat_flood_spl_team" "TODO: describe me" "g_chat_nospectators" "TODO: describe me" "g_chat_teamcolors" "TODO: describe me" "g_cloaked" "TODO: describe me" diff --git a/data/cvars.txt.pl b/data/cvars.txt.pl index 70814a876..d82f3c8cc 100644 --- a/data/cvars.txt.pl +++ b/data/cvars.txt.pl @@ -29,7 +29,9 @@ my $ignore_re = qr{ | vid_.* # client | g_banned_list # private -| g_ban_sync.* # private +| g_ban_default_.* # private +| g_ban_sync_.* # private +| g_chat_flood_.* # private | log_dest_udp # private | log_file # private | net_address # private @@ -71,6 +73,20 @@ my $ignore_re = qr{ | sv_motd # too long }x; +my %descr; +open my $fh, "<", "cvars.txt" + or die ") +{ + chomp; + /^"(.*?)\" \"(.*)\"$/ or next; + $descr{$1} = $2; +} +close $fh; + +open $fh, ">", "cvars.txt" + or die ">cvars.txt: $!"; + while() { chomp; @@ -87,11 +103,18 @@ while() } if($description eq 'custom cvar') { - print "\"$cvar\" \"TODO: describe me\"\n"; + if(defined $descr{$cvar}) + { + print $fh "\"$cvar\" \"$descr{$cvar}\"\n"; + } + else + { + print $fh "\"$cvar\" \"TODO: describe me\"\n"; + } } else { - print "\"$cvar\"\n"; + print $fh "\"$cvar\"\n"; } } } -- 2.39.2