diff options
| author | Mittendrein Markus <maxmitti@gmx.net> | 2015-09-02 18:20:13 +0200 |
|---|---|---|
| committer | Mittendrein Markus <maxmitti@gmx.net> | 2015-09-03 19:22:38 +0200 |
| commit | aba072f6403cbc9acd818da36e7baeec1a43fd06 (patch) | |
| tree | 2a824169db3084e4428697ec11951b23329abf86 /TemplePushing.c4s/Misc.c4d/SetupMenu.c4d | |
| parent | 736efdaf6aea46dc44322e84656a7a489face44a (diff) | |
| download | tempelschubsen-gamecomment.tar.gz tempelschubsen-gamecomment.zip | |
Show a option to disable GameComments if the host has the GameComment-featuregamecomment
Diffstat (limited to 'TemplePushing.c4s/Misc.c4d/SetupMenu.c4d')
| -rw-r--r-- | TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/Script.c | 17 | ||||
| -rw-r--r-- | TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblDE.txt | 3 | ||||
| -rw-r--r-- | TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblUS.txt | 3 |
3 files changed, 20 insertions, 3 deletions
diff --git a/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/Script.c b/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/Script.c index 11c2587..a3ec201 100644 --- a/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/Script.c +++ b/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/Script.c @@ -6,7 +6,7 @@ static const SETTING_Deathmatch = 0, SETTING_SuddenDeath = 1, SETTING_RotateInJump = 2, SETTING_RelaunchesInc = 3, SETTING_RelaunchesDec = 4, SETTING_DeathmatchScoreInc = 5, SETTING_DeathmatchScoreDec = 6, - SETTING_Ambience = 7; + SETTING_Ambience = 7, SETTING_GameComment = 8; local Sections, Modes; local clonk, setupPlayer; @@ -18,6 +18,8 @@ local ambienceEnabled; local numRelaunches; local deathmatchEnabled, deathmatchWinScore; +local useGameComment; + public func GetModes() { return @@ -38,6 +40,8 @@ protected func Initialize() section = Sections[0]; Modes = GetModes(); + + useGameComment = true; } private func ShowSetup() @@ -127,6 +131,13 @@ private func ShowSettingsMenu(bool preselect, int selectedSetting) CheckPreselect(preselect && selectedSetting == SETTING_DeathmatchScoreDec, menuItemIndex++); } + if (HaveHostFeature("GameComment")) + { + // GameComment entry + AddOptionMenuItem("$GameComment$", useGameComment, "SelectSetting(SETTING_GameComment)", ROCK); + CheckPreselect(preselect && selectedSetting == SETTING_GameComment, menuItemIndex++); + } + clonk->AddMenuItem("$Done$", "SetupDone()", SDNE); CheckPreselect(!preselect, menuItemIndex++); clonk->AddMenuItem("$Back$", "ShowModeMenu()", SBCK); @@ -166,6 +177,10 @@ private func SelectSetting(int selectedSetting) { deathmatchWinScore = Max(deathmatchWinScore - 1, 1); } + else if (selectedSetting == SETTING_GameComment) + { + useGameComment = !useGameComment; + } ShowMessage(); diff --git a/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblDE.txt b/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblDE.txt index ffe51b6..1b418d1 100644 --- a/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblDE.txt +++ b/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblDE.txt @@ -12,4 +12,5 @@ Mode=Modus Enabled=Aktiviert Disabled=Deaktiviert Ambience=Ambiente -Random=Zufällig
\ No newline at end of file +Random=Zufällig +GameComment=Info im Netzwerkkommentar diff --git a/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblUS.txt b/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblUS.txt index 07240dd..f53c996 100644 --- a/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblUS.txt +++ b/TemplePushing.c4s/Misc.c4d/SetupMenu.c4d/StringTblUS.txt @@ -12,4 +12,5 @@ Mode=Mode Enabled=Enabled Disabled=Disabled Ambience=Ambience -Random=Random
\ No newline at end of file +Random=Random +GameComment=Info in network comment |
