aboutsummaryrefslogtreecommitdiff
path: root/ShiftOS_TheReturn/AppLauncherDaemon.cs
diff options
context:
space:
mode:
authorMichael <[email protected]>2017-03-10 12:29:28 -0500
committerMichael <[email protected]>2017-03-10 12:29:28 -0500
commita9754b7df28795b6bb2c5cfe04c1b38b19fb0d05 (patch)
tree6ad4355d5c413df83b4e55710bc9850448279697 /ShiftOS_TheReturn/AppLauncherDaemon.cs
parenta9b08eb21676a6c59b0c8bb6046b40bd42e078d5 (diff)
downloadshiftos_thereturn-a9754b7df28795b6bb2c5cfe04c1b38b19fb0d05.tar.gz
shiftos_thereturn-a9754b7df28795b6bb2c5cfe04c1b38b19fb0d05.tar.bz2
shiftos_thereturn-a9754b7df28795b6bb2c5cfe04c1b38b19fb0d05.zip
Lock certain apps away when system offline.
Diffstat (limited to 'ShiftOS_TheReturn/AppLauncherDaemon.cs')
-rw-r--r--ShiftOS_TheReturn/AppLauncherDaemon.cs20
1 files changed, 16 insertions, 4 deletions
diff --git a/ShiftOS_TheReturn/AppLauncherDaemon.cs b/ShiftOS_TheReturn/AppLauncherDaemon.cs
index 7ef34c1..5e3bd72 100644
--- a/ShiftOS_TheReturn/AppLauncherDaemon.cs
+++ b/ShiftOS_TheReturn/AppLauncherDaemon.cs
@@ -66,12 +66,24 @@ namespace ShiftOS.Engine
{
foreach (var attr in type.GetCustomAttributes(false))
{
- if (attr is LauncherAttribute)
+ bool isAllowed = true;
+ if(attr is MultiplayerOnlyAttribute)
{
- var launch = attr as LauncherAttribute;
- if (launch.UpgradeInstalled)
+ if(KernelWatchdog.MudConnected == false)
{
- win.Add(new LauncherItem { DisplayData = launch, LaunchType = type });
+ isAllowed = false;
+
+ }
+ }
+ if (isAllowed == true)
+ {
+ if (attr is LauncherAttribute)
+ {
+ var launch = attr as LauncherAttribute;
+ if (launch.UpgradeInstalled)
+ {
+ win.Add(new LauncherItem { DisplayData = launch, LaunchType = type });
+ }
}
}
}