aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Application/Application.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Application/Application.cs')
-rw-r--r--OpenSim/Region/Application/Application.cs26
1 files changed, 21 insertions, 5 deletions
diff --git a/OpenSim/Region/Application/Application.cs b/OpenSim/Region/Application/Application.cs
index eaa4788..828490a 100644
--- a/OpenSim/Region/Application/Application.cs
+++ b/OpenSim/Region/Application/Application.cs
@@ -65,6 +65,12 @@ namespace OpenSim
65 65
66 ArgvConfigSource configSource = new ArgvConfigSource(args); 66 ArgvConfigSource configSource = new ArgvConfigSource(args);
67 67
68 configSource.Alias.AddAlias("On", true);
69 configSource.Alias.AddAlias("Off", false);
70 configSource.Alias.AddAlias("True", true);
71 configSource.Alias.AddAlias("False", false);
72
73 configSource.AddSwitch("Startup", "background");
68 configSource.AddSwitch("Startup", "inifile"); 74 configSource.AddSwitch("Startup", "inifile");
69 configSource.AddSwitch("Startup", "gridmode"); 75 configSource.AddSwitch("Startup", "gridmode");
70 configSource.AddSwitch("Startup", "physics"); 76 configSource.AddSwitch("Startup", "physics");
@@ -73,13 +79,23 @@ namespace OpenSim
73 configSource.AddConfig("StandAlone"); 79 configSource.AddConfig("StandAlone");
74 configSource.AddConfig("Network"); 80 configSource.AddConfig("Network");
75 81
76 OpenSimMain sim = new OpenSimMain(configSource); 82 bool background = configSource.Configs["Startup"].GetBoolean("background", false);
77
78 sim.StartUp();
79 83
80 while (true) 84 if (background)
85 {
86 Console.WriteLine("background mode");
87 OpenSimMain sim = new OpenSimMain(configSource);
88 sim.StartUp();
89 }
90 else
81 { 91 {
82 MainConsole.Instance.Prompt(); 92 OpenSimMain sim = new OpenSimMainConsole(configSource);
93 sim.StartUp();
94
95 while (true)
96 {
97 MainConsole.Instance.Prompt();
98 }
83 } 99 }
84 } 100 }
85 101