GameSettings, EnableDiscordService.
This commit is contained in:
@@ -262,6 +262,9 @@ namespace OpenRA
|
|||||||
public MPGameFilters MPGameFilters = MPGameFilters.Waiting | MPGameFilters.Empty | MPGameFilters.Protected | MPGameFilters.Started;
|
public MPGameFilters MPGameFilters = MPGameFilters.Waiting | MPGameFilters.Empty | MPGameFilters.Protected | MPGameFilters.Started;
|
||||||
|
|
||||||
public bool PauseShellmap = false;
|
public bool PauseShellmap = false;
|
||||||
|
|
||||||
|
[Desc("Allow mods to enable the Discord service that can interact with a local Discord client.")]
|
||||||
|
public bool EnableDiscordService = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public class Settings
|
public class Settings
|
||||||
|
|||||||
@@ -43,6 +43,9 @@ namespace OpenRA.Mods.Common
|
|||||||
if (instance != null)
|
if (instance != null)
|
||||||
return instance;
|
return instance;
|
||||||
|
|
||||||
|
if (!Game.Settings.Game.EnableDiscordService)
|
||||||
|
return null;
|
||||||
|
|
||||||
if (!Game.ModData.Manifest.Contains<DiscordService>())
|
if (!Game.ModData.Manifest.Contains<DiscordService>())
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user