aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/OptionalModules
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs1
-rw-r--r--OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCServer.cs1
-rw-r--r--OpenSim/Region/OptionalModules/Agent/UDP/Linden/LindenUDPInfoModule.cs73
-rw-r--r--OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs2
-rw-r--r--OpenSim/Region/OptionalModules/Avatar/Attachments/AttachmentsCommandModule.cs2
-rw-r--r--OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs1
-rw-r--r--OpenSim/Region/OptionalModules/Avatar/Friends/FriendsCommandsModule.cs2
-rwxr-xr-xOpenSim/Region/OptionalModules/PhysicsParameters/PhysicsParameters.cs2
-rw-r--r--OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs130
9 files changed, 106 insertions, 108 deletions
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
index 86f33eb..3b83e58 100644
--- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
+++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
@@ -38,6 +38,7 @@ using OpenMetaverse;
38using OpenMetaverse.Packets; 38using OpenMetaverse.Packets;
39using OpenSim.Framework; 39using OpenSim.Framework;
40using OpenSim.Framework.Client; 40using OpenSim.Framework.Client;
41using OpenSim.Framework.Monitoring;
41using OpenSim.Region.Framework.Scenes; 42using OpenSim.Region.Framework.Scenes;
42 43
43namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server 44namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCServer.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCServer.cs
index a7c5020..9d27386 100644
--- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCServer.cs
+++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCServer.cs
@@ -34,6 +34,7 @@ using System.Text;
34using System.Threading; 34using System.Threading;
35using log4net; 35using log4net;
36using OpenSim.Framework; 36using OpenSim.Framework;
37using OpenSim.Framework.Monitoring;
37using OpenSim.Region.Framework.Scenes; 38using OpenSim.Region.Framework.Scenes;
38 39
39namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server 40namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server
diff --git a/OpenSim/Region/OptionalModules/Agent/UDP/Linden/LindenUDPInfoModule.cs b/OpenSim/Region/OptionalModules/Agent/UDP/Linden/LindenUDPInfoModule.cs
index a7ebecc..5fe5948 100644
--- a/OpenSim/Region/OptionalModules/Agent/UDP/Linden/LindenUDPInfoModule.cs
+++ b/OpenSim/Region/OptionalModules/Agent/UDP/Linden/LindenUDPInfoModule.cs
@@ -35,7 +35,7 @@ using Nini.Config;
35using OpenMetaverse; 35using OpenMetaverse;
36using OpenSim.Framework; 36using OpenSim.Framework;
37using OpenSim.Framework.Console; 37using OpenSim.Framework.Console;
38using OpenSim.Framework.Statistics; 38using OpenSim.Framework.Monitoring;
39using OpenSim.Region.ClientStack.LindenUDP; 39using OpenSim.Region.ClientStack.LindenUDP;
40using OpenSim.Region.Framework.Interfaces; 40using OpenSim.Region.Framework.Interfaces;
41using OpenSim.Region.Framework.Scenes; 41using OpenSim.Region.Framework.Scenes;
@@ -82,18 +82,6 @@ namespace OpenSim.Region.CoreModules.UDP.Linden
82 m_scenes[scene.RegionInfo.RegionID] = scene; 82 m_scenes[scene.RegionInfo.RegionID] = scene;
83 83
84 scene.AddCommand( 84 scene.AddCommand(
85 "Comms", this, "image queues clear",
86 "image queues clear <first-name> <last-name>",
87 "Clear the image queues (textures downloaded via UDP) for a particular client.",
88 (mod, cmd) => MainConsole.Instance.Output(HandleImageQueuesClear(cmd)));
89
90 scene.AddCommand(
91 "Comms", this, "image queues show",
92 "image queues show <first-name> <last-name>",
93 "Show the image queues (textures downloaded via UDP) for a particular client.",
94 (mod, cmd) => MainConsole.Instance.Output(GetImageQueuesReport(cmd)));
95
96 scene.AddCommand(
97 "Comms", this, "show pqueues", 85 "Comms", this, "show pqueues",
98 "show pqueues [full]", 86 "show pqueues [full]",
99 "Show priority queue data for each client", 87 "Show priority queue data for each client",
@@ -105,8 +93,15 @@ namespace OpenSim.Region.CoreModules.UDP.Linden
105 "Comms", this, "show queues", 93 "Comms", this, "show queues",
106 "show queues [full]", 94 "show queues [full]",
107 "Show queue data for each client", 95 "Show queue data for each client",
108 "Without the 'full' option, only root agents are shown." 96 "Without the 'full' option, only root agents are shown.\n"
109 + " With the 'full' option child agents are also shown.", 97 + "With the 'full' option child agents are also shown.\n\n"
98 + "Type - Rt is a root (avatar) client whilst cd is a child (neighbour interacting) client.\n"
99 + "Since Last In - Time in milliseconds since last packet received.\n"
100 + "Pkts In - Number of packets processed from the client.\n"
101 + "Pkts Out - Number of packets sent to the client.\n"
102 + "Pkts Resent - Number of packets resent to the client.\n"
103 + "Bytes Unacked - Number of bytes transferred to the client that are awaiting acknowledgement.\n"
104 + "Q Pkts * - Number of packets of various types (land, wind, etc.) to be sent to the client that are waiting for available bandwidth.\n",
110 (mod, cmd) => MainConsole.Instance.Output(GetQueuesReport(cmd))); 105 (mod, cmd) => MainConsole.Instance.Output(GetQueuesReport(cmd)));
111 106
112 scene.AddCommand( 107 scene.AddCommand(
@@ -114,6 +109,12 @@ namespace OpenSim.Region.CoreModules.UDP.Linden
114 "show image queues <first-name> <last-name>", 109 "show image queues <first-name> <last-name>",
115 "Show the image queues (textures downloaded via UDP) for a particular client.", 110 "Show the image queues (textures downloaded via UDP) for a particular client.",
116 (mod, cmd) => MainConsole.Instance.Output(GetImageQueuesReport(cmd))); 111 (mod, cmd) => MainConsole.Instance.Output(GetImageQueuesReport(cmd)));
112
113 scene.AddCommand(
114 "Comms", this, "clear image queues",
115 "clear image queues <first-name> <last-name>",
116 "Clear the image queues (textures downloaded via UDP) for a particular client.",
117 (mod, cmd) => MainConsole.Instance.Output(HandleImageQueuesClear(cmd)));
117 118
118 scene.AddCommand( 119 scene.AddCommand(
119 "Comms", this, "show throttles", 120 "Comms", this, "show throttles",
@@ -373,17 +374,22 @@ namespace OpenSim.Region.CoreModules.UDP.Linden
373 int maxNameLength = 18; 374 int maxNameLength = 18;
374 int maxRegionNameLength = 14; 375 int maxRegionNameLength = 14;
375 int maxTypeLength = 4; 376 int maxTypeLength = 4;
376 int totalInfoFieldsLength = maxNameLength + columnPadding + maxRegionNameLength + columnPadding + maxTypeLength + columnPadding; 377
378 int totalInfoFieldsLength
379 = maxNameLength + columnPadding
380 + maxRegionNameLength + columnPadding
381 + maxTypeLength + columnPadding;
377 382
378 report.Append(GetColumnEntry("User", maxNameLength, columnPadding)); 383 report.Append(GetColumnEntry("User", maxNameLength, columnPadding));
379 report.Append(GetColumnEntry("Region", maxRegionNameLength, columnPadding)); 384 report.Append(GetColumnEntry("Region", maxRegionNameLength, columnPadding));
380 report.Append(GetColumnEntry("Type", maxTypeLength, columnPadding)); 385 report.Append(GetColumnEntry("Type", maxTypeLength, columnPadding));
381 386
382 report.AppendFormat( 387 report.AppendFormat(
383 "{0,7} {1,7} {2,7} {3,9} {4,7} {5,7} {6,7} {7,7} {8,7} {9,8} {10,7} {11,7}\n", 388 "{0,7} {1,7} {2,7} {3,7} {4,9} {5,7} {6,7} {7,7} {8,7} {9,7} {10,8} {11,7} {12,7}\n",
389 "Since",
390 "Pkts",
384 "Pkts", 391 "Pkts",
385 "Pkts", 392 "Pkts",
386 "Pkts",
387 "Bytes", 393 "Bytes",
388 "Q Pkts", 394 "Q Pkts",
389 "Q Pkts", 395 "Q Pkts",
@@ -396,7 +402,8 @@ namespace OpenSim.Region.CoreModules.UDP.Linden
396 402
397 report.AppendFormat("{0,-" + totalInfoFieldsLength + "}", ""); 403 report.AppendFormat("{0,-" + totalInfoFieldsLength + "}", "");
398 report.AppendFormat( 404 report.AppendFormat(
399 "{0,7} {1,7} {2,7} {3,9} {4,7} {5,7} {6,7} {7,7} {8,7} {9,8} {10,7} {11,7}\n", 405 "{0,7} {1,7} {2,7} {3,7} {4,9} {5,7} {6,7} {7,7} {8,7} {9,7} {10,8} {11,7} {12,7}\n",
406 "Last In",
400 "In", 407 "In",
401 "Out", 408 "Out",
402 "Resent", 409 "Resent",
@@ -417,22 +424,22 @@ namespace OpenSim.Region.CoreModules.UDP.Linden
417 scene.ForEachClient( 424 scene.ForEachClient(
418 delegate(IClientAPI client) 425 delegate(IClientAPI client)
419 { 426 {
420 if (client is IStatsCollector) 427 bool isChild = client.SceneAgent.IsChildAgent;
421 { 428 if (isChild && !showChildren)
422 bool isChild = client.SceneAgent.IsChildAgent; 429 return;
423 if (isChild && !showChildren) 430
424 return; 431 string name = client.Name;
425 432 if (pname != "" && name != pname)
426 string name = client.Name; 433 return;
427 if (pname != "" && name != pname)
428 return;
429 434
430 string regionName = scene.RegionInfo.RegionName; 435 string regionName = scene.RegionInfo.RegionName;
431 436
432 report.Append(GetColumnEntry(name, maxNameLength, columnPadding)); 437 report.Append(GetColumnEntry(name, maxNameLength, columnPadding));
433 report.Append(GetColumnEntry(regionName, maxRegionNameLength, columnPadding)); 438 report.Append(GetColumnEntry(regionName, maxRegionNameLength, columnPadding));
434 report.Append(GetColumnEntry(isChild ? "Cd" : "Rt", maxTypeLength, columnPadding)); 439 report.Append(GetColumnEntry(isChild ? "Cd" : "Rt", maxTypeLength, columnPadding));
435 440
441 if (client is IStatsCollector)
442 {
436 IStatsCollector stats = (IStatsCollector)client; 443 IStatsCollector stats = (IStatsCollector)client;
437 444
438 report.AppendLine(stats.Report()); 445 report.AppendLine(stats.Report());
diff --git a/OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs b/OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs
index 6bb6729..d718a2f 100644
--- a/OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs
+++ b/OpenSim/Region/OptionalModules/Avatar/Appearance/AppearanceInfoModule.cs
@@ -36,7 +36,7 @@ using Nini.Config;
36using OpenMetaverse; 36using OpenMetaverse;
37using OpenSim.Framework; 37using OpenSim.Framework;
38using OpenSim.Framework.Console; 38using OpenSim.Framework.Console;
39using OpenSim.Framework.Statistics; 39using OpenSim.Framework.Monitoring;
40using OpenSim.Region.ClientStack.LindenUDP; 40using OpenSim.Region.ClientStack.LindenUDP;
41using OpenSim.Region.Framework.Interfaces; 41using OpenSim.Region.Framework.Interfaces;
42using OpenSim.Region.Framework.Scenes; 42using OpenSim.Region.Framework.Scenes;
diff --git a/OpenSim/Region/OptionalModules/Avatar/Attachments/AttachmentsCommandModule.cs b/OpenSim/Region/OptionalModules/Avatar/Attachments/AttachmentsCommandModule.cs
index 1b9e3ac..d68aabc 100644
--- a/OpenSim/Region/OptionalModules/Avatar/Attachments/AttachmentsCommandModule.cs
+++ b/OpenSim/Region/OptionalModules/Avatar/Attachments/AttachmentsCommandModule.cs
@@ -36,7 +36,7 @@ using Nini.Config;
36using OpenMetaverse; 36using OpenMetaverse;
37using OpenSim.Framework; 37using OpenSim.Framework;
38using OpenSim.Framework.Console; 38using OpenSim.Framework.Console;
39using OpenSim.Framework.Statistics; 39using OpenSim.Framework.Monitoring;
40using OpenSim.Region.ClientStack.LindenUDP; 40using OpenSim.Region.ClientStack.LindenUDP;
41using OpenSim.Region.Framework.Interfaces; 41using OpenSim.Region.Framework.Interfaces;
42using OpenSim.Region.Framework.Scenes; 42using OpenSim.Region.Framework.Scenes;
diff --git a/OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs b/OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs
index cd401a6..ca956fb 100644
--- a/OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs
+++ b/OpenSim/Region/OptionalModules/Avatar/Chat/IRCConnector.cs
@@ -37,6 +37,7 @@ using OpenMetaverse;
37using log4net; 37using log4net;
38using Nini.Config; 38using Nini.Config;
39using OpenSim.Framework; 39using OpenSim.Framework;
40using OpenSim.Framework.Monitoring;
40using OpenSim.Region.Framework.Interfaces; 41using OpenSim.Region.Framework.Interfaces;
41using OpenSim.Region.Framework.Scenes; 42using OpenSim.Region.Framework.Scenes;
42 43
diff --git a/OpenSim/Region/OptionalModules/Avatar/Friends/FriendsCommandsModule.cs b/OpenSim/Region/OptionalModules/Avatar/Friends/FriendsCommandsModule.cs
index 2602050..4e84364 100644
--- a/OpenSim/Region/OptionalModules/Avatar/Friends/FriendsCommandsModule.cs
+++ b/OpenSim/Region/OptionalModules/Avatar/Friends/FriendsCommandsModule.cs
@@ -37,7 +37,7 @@ using Nini.Config;
37using OpenMetaverse; 37using OpenMetaverse;
38using OpenSim.Framework; 38using OpenSim.Framework;
39using OpenSim.Framework.Console; 39using OpenSim.Framework.Console;
40using OpenSim.Framework.Statistics; 40using OpenSim.Framework.Monitoring;
41using OpenSim.Region.ClientStack.LindenUDP; 41using OpenSim.Region.ClientStack.LindenUDP;
42using OpenSim.Region.CoreModules.Avatar.Friends; 42using OpenSim.Region.CoreModules.Avatar.Friends;
43using OpenSim.Region.Framework.Interfaces; 43using OpenSim.Region.Framework.Interfaces;
diff --git a/OpenSim/Region/OptionalModules/PhysicsParameters/PhysicsParameters.cs b/OpenSim/Region/OptionalModules/PhysicsParameters/PhysicsParameters.cs
index e452124..40f7fbc 100755
--- a/OpenSim/Region/OptionalModules/PhysicsParameters/PhysicsParameters.cs
+++ b/OpenSim/Region/OptionalModules/PhysicsParameters/PhysicsParameters.cs
@@ -47,7 +47,7 @@ namespace OpenSim.Region.OptionalModules.PhysicsParameters
47 [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule", Id = "PhysicsParameters")] 47 [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule", Id = "PhysicsParameters")]
48 public class PhysicsParameters : ISharedRegionModule 48 public class PhysicsParameters : ISharedRegionModule
49 { 49 {
50 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 50// private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
51// private static string LogHeader = "[PHYSICS PARAMETERS]"; 51// private static string LogHeader = "[PHYSICS PARAMETERS]";
52 52
53 private List<Scene> m_scenes = new List<Scene>(); 53 private List<Scene> m_scenes = new List<Scene>();
diff --git a/OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs b/OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs
index 600cafb..fff3a32 100644
--- a/OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs
+++ b/OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs
@@ -31,16 +31,14 @@ using System.Reflection;
31using System.Net; 31using System.Net;
32using System.IO; 32using System.IO;
33using System.Text; 33using System.Text;
34
35using log4net; 34using log4net;
36using Nini.Config; 35using Nini.Config;
37using OpenMetaverse; 36using OpenMetaverse;
38using OpenMetaverse.StructuredData; 37using OpenMetaverse.StructuredData;
39using OpenSim.Services.Interfaces;
40
41using OpenSim.Framework; 38using OpenSim.Framework;
42using OpenSim.Region.Framework.Interfaces; 39using OpenSim.Region.Framework.Interfaces;
43using OpenSim.Region.Framework.Scenes; 40using OpenSim.Region.Framework.Scenes;
41using OpenSim.Services.Interfaces;
44 42
45namespace OpenSim.Region.OptionalModules.Scripting.RegionReady 43namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
46{ 44{
@@ -50,16 +48,15 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
50 LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 48 LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
51 49
52 private IConfig m_config = null; 50 private IConfig m_config = null;
53 private bool m_ScriptRez;
54 private bool m_firstEmptyCompileQueue; 51 private bool m_firstEmptyCompileQueue;
55 private bool m_oarFileLoading; 52 private bool m_oarFileLoading;
56 private bool m_lastOarLoadedOk; 53 private bool m_lastOarLoadedOk;
57 private int m_channelNotify = -1000; 54 private int m_channelNotify = -1000;
58 private bool m_enabled = false; 55 private bool m_enabled = false;
59 private bool m_disable_logins = false; 56 private bool m_disable_logins;
60 private string m_uri = string.Empty; 57 private string m_uri = string.Empty;
61 58
62 Scene m_scene = null; 59 Scene m_scene;
63 60
64 #region INonSharedRegionModule interface 61 #region INonSharedRegionModule interface
65 62
@@ -93,53 +90,40 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
93 90
94 m_scene.RegisterModuleInterface<IRegionReadyModule>(this); 91 m_scene.RegisterModuleInterface<IRegionReadyModule>(this);
95 92
96 m_ScriptRez = false;
97 m_firstEmptyCompileQueue = true; 93 m_firstEmptyCompileQueue = true;
98 m_oarFileLoading = false; 94 m_oarFileLoading = false;
99 m_lastOarLoadedOk = true; 95 m_lastOarLoadedOk = true;
100 96
101 m_scene.EventManager.OnOarFileLoaded += OnOarFileLoaded; 97 m_scene.EventManager.OnOarFileLoaded += OnOarFileLoaded;
102 m_scene.EventManager.OnRezScript += OnRezScript;
103 m_scene.EventManager.OnLoginsEnabled += OnLoginsEnabled;
104 98
105 m_log.DebugFormat("[RegionReady]: Enabled for region {0}", scene.RegionInfo.RegionName); 99 m_log.DebugFormat("[RegionReady]: Enabled for region {0}", scene.RegionInfo.RegionName);
106 100
107 if (m_disable_logins == true) 101 if (m_disable_logins)
108 { 102 {
109 scene.LoginLock = true; 103 m_scene.LoginLock = true;
110 scene.LoginsDisabled = true; 104 m_scene.EventManager.OnEmptyScriptCompileQueue += OnEmptyScriptCompileQueue;
111 m_log.InfoFormat("[RegionReady]: Region {0} - logins disabled during initialization.",m_scene.RegionInfo.RegionName); 105
106 m_log.InfoFormat("[RegionReady]: Region {0} - LOGINS DISABLED DURING INITIALIZATION.", m_scene.Name);
112 107
113 if(m_uri != string.Empty) 108 if (m_uri != string.Empty)
114 { 109 {
115 RRAlert("disabled"); 110 RRAlert("disabled");
116 } 111 }
117 } 112 }
118 } 113 }
119 114
120 void OnRezScript (uint localID, UUID itemID, string script, int startParam, bool postOnRez, string engine, int stateSource)
121 {
122 if (!m_ScriptRez)
123 {
124 m_ScriptRez = true;
125 m_scene.EventManager.OnEmptyScriptCompileQueue += OnEmptyScriptCompileQueue;
126 m_scene.EventManager.OnRezScript -= OnRezScript;
127 }
128 }
129
130 public void RemoveRegion(Scene scene) 115 public void RemoveRegion(Scene scene)
131 { 116 {
132 if (!m_enabled) 117 if (!m_enabled)
133 return; 118 return;
134 119
135 m_scene.EventManager.OnEmptyScriptCompileQueue -= OnEmptyScriptCompileQueue;
136 m_scene.EventManager.OnOarFileLoaded -= OnOarFileLoaded; 120 m_scene.EventManager.OnOarFileLoaded -= OnOarFileLoaded;
137 m_scene.EventManager.OnLoginsEnabled -= OnLoginsEnabled;
138 121
139 if(m_uri != string.Empty) 122 if (m_disable_logins)
140 { 123 m_scene.EventManager.OnEmptyScriptCompileQueue -= OnEmptyScriptCompileQueue;
124
125 if (m_uri != string.Empty)
141 RRAlert("shutdown"); 126 RRAlert("shutdown");
142 }
143 127
144 m_scene = null; 128 m_scene = null;
145 } 129 }
@@ -159,7 +143,6 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
159 143
160 #endregion 144 #endregion
161 145
162
163 void OnEmptyScriptCompileQueue(int numScriptsFailed, string message) 146 void OnEmptyScriptCompileQueue(int numScriptsFailed, string message)
164 { 147 {
165 m_log.DebugFormat("[RegionReady]: Script compile queue empty!"); 148 m_log.DebugFormat("[RegionReady]: Script compile queue empty!");
@@ -193,75 +176,80 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
193 m_scene.RegionInfo.RegionName, c.Message, m_channelNotify); 176 m_scene.RegionInfo.RegionName, c.Message, m_channelNotify);
194 177
195 m_scene.EventManager.TriggerOnChatBroadcast(this, c); 178 m_scene.EventManager.TriggerOnChatBroadcast(this, c);
196 m_scene.EventManager.TriggerLoginsEnabled(m_scene.RegionInfo.RegionName); 179
197 m_scene.SceneGridService.InformNeighborsThatRegionisUp(m_scene.RequestModuleInterface<INeighbourService>(), m_scene.RegionInfo); 180 TriggerRegionReady(m_scene);
198 } 181 }
199 } 182 }
200 183
201 void OnOarFileLoaded(Guid requestId, string message) 184 void OnOarFileLoaded(Guid requestId, string message)
202 { 185 {
203 m_oarFileLoading = true; 186 m_oarFileLoading = true;
187
204 if (message==String.Empty) 188 if (message==String.Empty)
205 { 189 {
206 m_lastOarLoadedOk = true; 190 m_lastOarLoadedOk = true;
207 } else { 191 }
192 else
193 {
208 m_log.WarnFormat("[RegionReady]: Oar file load errors: {0}", message); 194 m_log.WarnFormat("[RegionReady]: Oar file load errors: {0}", message);
209 m_lastOarLoadedOk = false; 195 m_lastOarLoadedOk = false;
210 } 196 }
211 } 197 }
212 198
213 // This will be triggerd by Scene if we have no scripts 199 /// <summary>
214 // m_ScriptsRezzing will be false if there were none 200 /// This will be triggered by Scene directly if it contains no scripts on startup. Otherwise it is triggered
215 // else it will be true and we should wait on the 201 /// when the script compile queue is empty after initial region startup.
216 // empty compile queue 202 /// </summary>
217 void OnLoginsEnabled(string regionName) 203 /// <param name='scene'></param>
204 public void TriggerRegionReady(IScene scene)
218 { 205 {
219 if (m_disable_logins == true) 206 m_scene.EventManager.OnEmptyScriptCompileQueue -= OnEmptyScriptCompileQueue;
207 m_scene.LoginLock = false;
208
209 if (!m_scene.StartDisabled)
220 { 210 {
221 if (m_scene.StartDisabled == false) 211 m_scene.LoginsEnabled = true;
222 {
223 m_scene.LoginsDisabled = false;
224 m_scene.LoginLock = false;
225 212
226 m_scene.EventManager.OnEmptyScriptCompileQueue -= OnEmptyScriptCompileQueue; 213 // m_log.InfoFormat("[RegionReady]: Logins enabled for {0}, Oar {1}",
214 // m_scene.RegionInfo.RegionName, m_oarFileLoading.ToString());
227 215
228 // m_log.InfoFormat("[RegionReady]: Logins enabled for {0}, Oar {1}", 216 m_log.InfoFormat(
229 // m_scene.RegionInfo.RegionName, m_oarFileLoading.ToString()); 217 "[RegionReady]: INITIALIZATION COMPLETE FOR {0} - LOGINS ENABLED", m_scene.Name);
218 }
230 219
231 m_log.InfoFormat( 220 m_scene.SceneGridService.InformNeighborsThatRegionisUp(
232 "[RegionReady]: INITIALIZATION COMPLETE FOR {0} - LOGINS ENABLED", m_scene.Name); 221 m_scene.RequestModuleInterface<INeighbourService>(), m_scene.RegionInfo);
233 222
234 if (m_uri != string.Empty) 223 if (m_uri != string.Empty)
235 { 224 {
236 RRAlert("enabled"); 225 RRAlert("enabled");
237 }
238 }
239 } 226 }
227
228 m_scene.Ready = true;
240 } 229 }
241 230
242 public void OarLoadingAlert(string msg) 231 public void OarLoadingAlert(string msg)
243 { 232 {
244 // Let's bypass this for now until some better feedback can be established 233 // Let's bypass this for now until some better feedback can be established
245 // 234 //
246 return;
247 235
248 if (msg == "load") 236// if (msg == "load")
249 { 237// {
250 m_scene.EventManager.OnEmptyScriptCompileQueue += OnEmptyScriptCompileQueue; 238// m_scene.EventManager.OnEmptyScriptCompileQueue += OnEmptyScriptCompileQueue;
251 m_scene.EventManager.OnOarFileLoaded += OnOarFileLoaded; 239// m_scene.EventManager.OnOarFileLoaded += OnOarFileLoaded;
252 m_scene.EventManager.OnLoginsEnabled += OnLoginsEnabled; 240// m_scene.EventManager.OnLoginsEnabled += OnLoginsEnabled;
253 m_scene.EventManager.OnRezScript += OnRezScript; 241// m_scene.EventManager.OnRezScript += OnRezScript;
254 m_oarFileLoading = true; 242// m_oarFileLoading = true;
255 m_firstEmptyCompileQueue = true; 243// m_firstEmptyCompileQueue = true;
256 244//
257 m_scene.LoginsDisabled = true; 245// m_scene.LoginsDisabled = true;
258 m_scene.LoginLock = true; 246// m_scene.LoginLock = true;
259 if ( m_uri != string.Empty ) 247// if ( m_uri != string.Empty )
260 { 248// {
261 RRAlert("loading oar"); 249// RRAlert("loading oar");
262 RRAlert("disabled"); 250// RRAlert("disabled");
263 } 251// }
264 } 252// }
265 } 253 }
266 254
267 public void RRAlert(string status) 255 public void RRAlert(string status)