Removes the MapMusic checkbox.
This commit is contained in:
@@ -108,7 +108,6 @@ namespace OpenRA
|
|||||||
|
|
||||||
public bool Shuffle = false;
|
public bool Shuffle = false;
|
||||||
public bool Repeat = false;
|
public bool Repeat = false;
|
||||||
public bool MapMusic = true;
|
|
||||||
|
|
||||||
public string Engine = "AL";
|
public string Engine = "AL";
|
||||||
public string Device = null;
|
public string Device = null;
|
||||||
|
|||||||
@@ -44,8 +44,7 @@ namespace OpenRA.Traits
|
|||||||
|
|
||||||
random = playlist.Shuffle(Game.CosmeticRandom).ToArray();
|
random = playlist.Shuffle(Game.CosmeticRandom).ToArray();
|
||||||
|
|
||||||
if (Game.Settings.Sound.MapMusic
|
if (!string.IsNullOrEmpty(info.StartingMusic)
|
||||||
&& !string.IsNullOrEmpty(info.StartingMusic)
|
|
||||||
&& world.Map.Rules.Music.ContainsKey(info.StartingMusic)
|
&& world.Map.Rules.Music.ContainsKey(info.StartingMusic)
|
||||||
&& world.Map.Rules.Music[info.StartingMusic].Exists)
|
&& world.Map.Rules.Music[info.StartingMusic].Exists)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ namespace OpenRA.Mods.Common.Scripting
|
|||||||
[Desc("Play track defined in music.yaml or keep it empty for a random song.")]
|
[Desc("Play track defined in music.yaml or keep it empty for a random song.")]
|
||||||
public void PlayMusic(string track = null, LuaFunction func = null)
|
public void PlayMusic(string track = null, LuaFunction func = null)
|
||||||
{
|
{
|
||||||
if (!Game.Settings.Sound.MapMusic || !playlist.IsMusicAvailable)
|
if (!playlist.IsMusicAvailable)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
var musicInfo = !string.IsNullOrEmpty(track) ? world.Map.Rules.Music[track]
|
var musicInfo = !string.IsNullOrEmpty(track) ? world.Map.Rules.Music[track]
|
||||||
|
|||||||
@@ -263,7 +263,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
{
|
{
|
||||||
var ss = Game.Settings.Sound;
|
var ss = Game.Settings.Sound;
|
||||||
|
|
||||||
BindCheckboxPref(panel, "SHELLMAP_MUSIC", ss, "MapMusic");
|
|
||||||
BindCheckboxPref(panel, "CASH_TICKS", ss, "CashTicks");
|
BindCheckboxPref(panel, "CASH_TICKS", ss, "CashTicks");
|
||||||
|
|
||||||
BindSliderPref(panel, "SOUND_VOLUME", ss, "SoundVolume");
|
BindSliderPref(panel, "SOUND_VOLUME", ss, "SoundVolume");
|
||||||
@@ -295,7 +294,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
var dss = new SoundSettings();
|
var dss = new SoundSettings();
|
||||||
return () =>
|
return () =>
|
||||||
{
|
{
|
||||||
ss.MapMusic = dss.MapMusic;
|
|
||||||
ss.SoundVolume = dss.SoundVolume;
|
ss.SoundVolume = dss.SoundVolume;
|
||||||
ss.MusicVolume = dss.MusicVolume;
|
ss.MusicVolume = dss.MusicVolume;
|
||||||
ss.VideoVolume = dss.VideoVolume;
|
ss.VideoVolume = dss.VideoVolume;
|
||||||
|
|||||||
@@ -238,13 +238,6 @@ Container@SETTINGS_PANEL:
|
|||||||
Font: Bold
|
Font: Bold
|
||||||
Text: Audio
|
Text: Audio
|
||||||
Align: Center
|
Align: Center
|
||||||
Checkbox@SHELLMAP_MUSIC:
|
|
||||||
X: 15
|
|
||||||
Y: 40
|
|
||||||
Width: 200
|
|
||||||
Height: 20
|
|
||||||
Font: Regular
|
|
||||||
Text: Shellmap / Mission Music
|
|
||||||
Label@SOUND_LABEL:
|
Label@SOUND_LABEL:
|
||||||
X: PARENT_RIGHT - WIDTH - 270
|
X: PARENT_RIGHT - WIDTH - 270
|
||||||
Y: 37
|
Y: 37
|
||||||
@@ -260,7 +253,7 @@ Container@SETTINGS_PANEL:
|
|||||||
Ticks: 5
|
Ticks: 5
|
||||||
Checkbox@CASH_TICKS:
|
Checkbox@CASH_TICKS:
|
||||||
X: 15
|
X: 15
|
||||||
Y: 70
|
Y: 40
|
||||||
Width: 200
|
Width: 200
|
||||||
Height: 20
|
Height: 20
|
||||||
Font: Regular
|
Font: Regular
|
||||||
|
|||||||
@@ -246,13 +246,6 @@ Background@SETTINGS_PANEL:
|
|||||||
Width: PARENT_RIGHT - 10
|
Width: PARENT_RIGHT - 10
|
||||||
Height: PARENT_BOTTOM
|
Height: PARENT_BOTTOM
|
||||||
Children:
|
Children:
|
||||||
Checkbox@SHELLMAP_MUSIC:
|
|
||||||
X: 15
|
|
||||||
Y: 40
|
|
||||||
Width: 200
|
|
||||||
Height: 20
|
|
||||||
Font: Regular
|
|
||||||
Text: Shellmap / Mission Music
|
|
||||||
Label@SOUND_LABEL:
|
Label@SOUND_LABEL:
|
||||||
X: PARENT_RIGHT - WIDTH - 270
|
X: PARENT_RIGHT - WIDTH - 270
|
||||||
Y: 37
|
Y: 37
|
||||||
@@ -268,7 +261,7 @@ Background@SETTINGS_PANEL:
|
|||||||
Ticks: 5
|
Ticks: 5
|
||||||
Checkbox@CASH_TICKS:
|
Checkbox@CASH_TICKS:
|
||||||
X: 15
|
X: 15
|
||||||
Y: 70
|
Y: 40
|
||||||
Width: 200
|
Width: 200
|
||||||
Height: 20
|
Height: 20
|
||||||
Font: Regular
|
Font: Regular
|
||||||
|
|||||||
Reference in New Issue
Block a user