diff options
author | Jeff Ames | 2008-05-14 05:33:32 +0000 |
---|---|---|
committer | Jeff Ames | 2008-05-14 05:33:32 +0000 |
commit | 6a1b787436cc59043a26a296781e7a7b5ea0c67b (patch) | |
tree | 10f55a7b0abfdc47f103d40f13f3cae530c13581 /OpenSim/Region | |
parent | Formatting cleanup. (diff) | |
download | opensim-SC_OLD-6a1b787436cc59043a26a296781e7a7b5ea0c67b.zip opensim-SC_OLD-6a1b787436cc59043a26a296781e7a7b5ea0c67b.tar.gz opensim-SC_OLD-6a1b787436cc59043a26a296781e7a7b5ea0c67b.tar.bz2 opensim-SC_OLD-6a1b787436cc59043a26a296781e7a7b5ea0c67b.tar.xz |
More formatting cleanup.
Diffstat (limited to 'OpenSim/Region')
9 files changed, 61 insertions, 46 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs index af20687..32432b4 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | |||
@@ -4601,13 +4601,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
4601 | ObjectIncludeInSearchPacket packInSearch = (ObjectIncludeInSearchPacket)Pack; | 4601 | ObjectIncludeInSearchPacket packInSearch = (ObjectIncludeInSearchPacket)Pack; |
4602 | handlerObjectIncludeInSearch = null; | 4602 | handlerObjectIncludeInSearch = null; |
4603 | 4603 | ||
4604 | foreach (ObjectIncludeInSearchPacket.ObjectDataBlock objData in packInSearch.ObjectData) { | 4604 | foreach (ObjectIncludeInSearchPacket.ObjectDataBlock objData in packInSearch.ObjectData) |
4605 | { | ||
4605 | bool inSearch = objData.IncludeInSearch; | 4606 | bool inSearch = objData.IncludeInSearch; |
4606 | uint localID = objData.ObjectLocalID; | 4607 | uint localID = objData.ObjectLocalID; |
4607 | 4608 | ||
4608 | handlerObjectIncludeInSearch = OnObjectIncludeInSearch; | 4609 | handlerObjectIncludeInSearch = OnObjectIncludeInSearch; |
4609 | 4610 | ||
4610 | if (handlerObjectIncludeInSearch != null) { | 4611 | if (handlerObjectIncludeInSearch != null) |
4612 | { | ||
4611 | handlerObjectIncludeInSearch(this, inSearch, localID); | 4613 | handlerObjectIncludeInSearch(this, inSearch, localID); |
4612 | } | 4614 | } |
4613 | } | 4615 | } |
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLPacketQueue.cs b/OpenSim/Region/ClientStack/LindenUDP/LLPacketQueue.cs index c6da96e..8f90f34 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLPacketQueue.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLPacketQueue.cs | |||
@@ -148,7 +148,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
148 | return; | 148 | return; |
149 | } | 149 | } |
150 | 150 | ||
151 | lock (this) { | 151 | lock (this) |
152 | { | ||
152 | switch (item.throttleType) | 153 | switch (item.throttleType) |
153 | { | 154 | { |
154 | case ThrottleOutPacketType.Resend: | 155 | case ThrottleOutPacketType.Resend: |
diff --git a/OpenSim/Region/DataSnapshot/DataSnapshotManager.cs b/OpenSim/Region/DataSnapshot/DataSnapshotManager.cs index 245922c..5831ddc 100644 --- a/OpenSim/Region/DataSnapshot/DataSnapshotManager.cs +++ b/OpenSim/Region/DataSnapshot/DataSnapshotManager.cs | |||
@@ -78,43 +78,47 @@ namespace OpenSim.Region.DataSnapshot | |||
78 | if (!m_scenes.Contains(scene)) | 78 | if (!m_scenes.Contains(scene)) |
79 | m_scenes.Add(scene); | 79 | m_scenes.Add(scene); |
80 | 80 | ||
81 | if (!m_configLoaded) { | 81 | if (!m_configLoaded) |
82 | { | ||
82 | m_configLoaded = true; | 83 | m_configLoaded = true; |
83 | m_log.Info("[DATASNAPSHOT]: Loading configuration"); | 84 | m_log.Info("[DATASNAPSHOT]: Loading configuration"); |
84 | //Read from the config for options | 85 | //Read from the config for options |
85 | lock (m_syncInit) { | 86 | lock (m_syncInit) |
86 | try { | 87 | { |
87 | m_enabled = config.Configs["DataSnapshot"].GetBoolean("index_sims", m_enabled); | 88 | try |
88 | if (config.Configs["Startup"].GetBoolean("gridmode", true)) | 89 | { |
89 | { | 90 | m_enabled = config.Configs["DataSnapshot"].GetBoolean("index_sims", m_enabled); |
90 | m_gridinfo.Add("gridserverURL", config.Configs["Network"].GetString("grid_server_url", "harbl")); | 91 | if (config.Configs["Startup"].GetBoolean("gridmode", true)) |
91 | m_gridinfo.Add("userserverURL", config.Configs["Network"].GetString("user_server_url", "harbl")); | 92 | { |
92 | m_gridinfo.Add("assetserverURL", config.Configs["Network"].GetString("asset_server_url", "harbl")); | 93 | m_gridinfo.Add("gridserverURL", config.Configs["Network"].GetString("grid_server_url", "harbl")); |
93 | } | 94 | m_gridinfo.Add("userserverURL", config.Configs["Network"].GetString("user_server_url", "harbl")); |
94 | else | 95 | m_gridinfo.Add("assetserverURL", config.Configs["Network"].GetString("asset_server_url", "harbl")); |
95 | { | 96 | } |
96 | //Non gridmode stuff | 97 | else |
97 | } | 98 | { |
98 | 99 | //Non gridmode stuff | |
99 | m_gridinfo.Add("Name", config.Configs["DataSnapshot"].GetString("gridname", "harbl")); | 100 | } |
100 | m_maxSnapshots = config.Configs["DataSnapshot"].GetInt("max_snapshots", m_maxSnapshots); | 101 | |
101 | m_period = config.Configs["DataSnapshot"].GetInt("default_snapshot_period", m_period); | 102 | m_gridinfo.Add("Name", config.Configs["DataSnapshot"].GetString("gridname", "harbl")); |
102 | m_snapsDir = config.Configs["DataSnapshot"].GetString("snapshot_cache_directory", m_snapsDir); | 103 | m_maxSnapshots = config.Configs["DataSnapshot"].GetInt("max_snapshots", m_maxSnapshots); |
103 | m_dataServices = config.Configs["DataSnapshot"].GetString("data_services", m_dataServices); | 104 | m_period = config.Configs["DataSnapshot"].GetInt("default_snapshot_period", m_period); |
104 | m_listener_port = config.Configs["Network"].GetString("http_listener_port", m_listener_port); | 105 | m_snapsDir = config.Configs["DataSnapshot"].GetString("snapshot_cache_directory", m_snapsDir); |
105 | //BUG: Naming a search data module "DESUDESUDESU" will cause it to not get loaded by default. | 106 | m_dataServices = config.Configs["DataSnapshot"].GetString("data_services", m_dataServices); |
106 | //RESOLUTION: Wontfix, there are no Suiseiseki-loving developers | 107 | m_listener_port = config.Configs["Network"].GetString("http_listener_port", m_listener_port); |
107 | String[] annoying_string_array = config.Configs["DataSnapshot"].GetString("disable_modules", "DESUDESUDESU").Split(".".ToCharArray()); | 108 | //BUG: Naming a search data module "DESUDESUDESU" will cause it to not get loaded by default. |
108 | foreach (String bloody_wanker in annoying_string_array) { | 109 | //RESOLUTION: Wontfix, there are no Suiseiseki-loving developers |
109 | m_disabledModules.Add(bloody_wanker); | 110 | String[] annoying_string_array = config.Configs["DataSnapshot"].GetString("disable_modules", "DESUDESUDESU").Split(".".ToCharArray()); |
110 | } | 111 | foreach (String bloody_wanker in annoying_string_array) |
111 | 112 | { | |
112 | } catch (Exception) { | 113 | m_disabledModules.Add(bloody_wanker); |
114 | } | ||
115 | } | ||
116 | catch (Exception) | ||
117 | { | ||
113 | m_log.Info("[DATASNAPSHOT]: Could not load configuration. DataSnapshot will be disabled."); | 118 | m_log.Info("[DATASNAPSHOT]: Could not load configuration. DataSnapshot will be disabled."); |
114 | m_enabled = false; | 119 | m_enabled = false; |
115 | return; | 120 | return; |
116 | } | 121 | } |
117 | |||
118 | } | 122 | } |
119 | } | 123 | } |
120 | if (Directory.Exists(m_snapsDir)) | 124 | if (Directory.Exists(m_snapsDir)) |
@@ -135,7 +139,6 @@ namespace OpenSim.Region.DataSnapshot | |||
135 | } | 139 | } |
136 | } | 140 | } |
137 | 141 | ||
138 | |||
139 | if (m_enabled) | 142 | if (m_enabled) |
140 | { | 143 | { |
141 | m_log.Info("[DATASNAPSHOT]: Scene added to module."); | 144 | m_log.Info("[DATASNAPSHOT]: Scene added to module."); |
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs index efd258d..82a6b94 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | |||
@@ -815,7 +815,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
815 | agentItem.Folder = folderId; | 815 | agentItem.Folder = folderId; |
816 | agentItem.EveryOnePermissions = taskItem.EveryoneMask; | 816 | agentItem.EveryOnePermissions = taskItem.EveryoneMask; |
817 | 817 | ||
818 | if (remoteClient.AgentId != taskItem.OwnerID) { | 818 | if (remoteClient.AgentId != taskItem.OwnerID) |
819 | { | ||
819 | agentItem.BasePermissions = taskItem.NextOwnerMask; | 820 | agentItem.BasePermissions = taskItem.NextOwnerMask; |
820 | agentItem.CurrentPermissions = taskItem.NextOwnerMask; | 821 | agentItem.CurrentPermissions = taskItem.NextOwnerMask; |
821 | agentItem.NextPermissions = taskItem.NextOwnerMask; | 822 | agentItem.NextPermissions = taskItem.NextOwnerMask; |
@@ -1038,7 +1039,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
1038 | item.InvType = asset.InvType; | 1039 | item.InvType = asset.InvType; |
1039 | item.Folder = DeRezPacket.AgentBlock.DestinationID; | 1040 | item.Folder = DeRezPacket.AgentBlock.DestinationID; |
1040 | item.EveryOnePermissions = objectGroup.RootPart.EveryoneMask; | 1041 | item.EveryOnePermissions = objectGroup.RootPart.EveryoneMask; |
1041 | if (remoteClient.AgentId != objectGroup.RootPart.OwnerID) { | 1042 | if (remoteClient.AgentId != objectGroup.RootPart.OwnerID) |
1043 | { | ||
1042 | item.BasePermissions = objectGroup.RootPart.NextOwnerMask; | 1044 | item.BasePermissions = objectGroup.RootPart.NextOwnerMask; |
1043 | item.CurrentPermissions = objectGroup.RootPart.NextOwnerMask; | 1045 | item.CurrentPermissions = objectGroup.RootPart.NextOwnerMask; |
1044 | item.NextPermissions = objectGroup.RootPart.NextOwnerMask; | 1046 | item.NextPermissions = objectGroup.RootPart.NextOwnerMask; |
diff --git a/OpenSim/Region/Environment/Scenes/SceneEvents.cs b/OpenSim/Region/Environment/Scenes/SceneEvents.cs index 88537e9..dacd609 100644 --- a/OpenSim/Region/Environment/Scenes/SceneEvents.cs +++ b/OpenSim/Region/Environment/Scenes/SceneEvents.cs | |||
@@ -195,7 +195,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
195 | public int transactiontype; | 195 | public int transactiontype; |
196 | public string description; | 196 | public string description; |
197 | 197 | ||
198 | public MoneyTransferArgs(LLUUID asender, LLUUID areceiver, int aamount, int atransactiontype, string adescription) { | 198 | public MoneyTransferArgs(LLUUID asender, LLUUID areceiver, int aamount, int atransactiontype, string adescription) |
199 | { | ||
199 | sender = asender; | 200 | sender = asender; |
200 | receiver = areceiver; | 201 | receiver = areceiver; |
201 | amount = aamount; | 202 | amount = aamount; |
diff --git a/OpenSim/Region/Physics/Meshing/Meshmerizer.cs b/OpenSim/Region/Physics/Meshing/Meshmerizer.cs index 5008927..2e7ec15 100644 --- a/OpenSim/Region/Physics/Meshing/Meshmerizer.cs +++ b/OpenSim/Region/Physics/Meshing/Meshmerizer.cs | |||
@@ -579,7 +579,8 @@ namespace OpenSim.Region.Physics.Meshing | |||
579 | 579 | ||
580 | if (pathShearX != 0) | 580 | if (pathShearX != 0) |
581 | { | 581 | { |
582 | if (pathShearX > 50) { | 582 | if (pathShearX > 50) |
583 | { | ||
583 | // Complimentary byte. Negative values wrap around the byte. Positive values go up to 50 | 584 | // Complimentary byte. Negative values wrap around the byte. Positive values go up to 50 |
584 | extr.pushX = (((float)(256 - pathShearX) / 100) * -1f); | 585 | extr.pushX = (((float)(256 - pathShearX) / 100) * -1f); |
585 | // m_log.Warn("pushX: " + extr.pushX); | 586 | // m_log.Warn("pushX: " + extr.pushX); |
@@ -593,7 +594,8 @@ namespace OpenSim.Region.Physics.Meshing | |||
593 | 594 | ||
594 | if (pathShearY != 0) | 595 | if (pathShearY != 0) |
595 | { | 596 | { |
596 | if (pathShearY > 50) { | 597 | if (pathShearY > 50) |
598 | { | ||
597 | // Complimentary byte. Negative values wrap around the byte. Positive values go up to 50 | 599 | // Complimentary byte. Negative values wrap around the byte. Positive values go up to 50 |
598 | extr.pushY = (((float)(256 - pathShearY) / 100) * -1f); | 600 | extr.pushY = (((float)(256 - pathShearY) / 100) * -1f); |
599 | //m_log.Warn("pushY: " + extr.pushY); | 601 | //m_log.Warn("pushY: " + extr.pushY); |
diff --git a/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs b/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs index a54523b..c2a1c8e 100644 --- a/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs +++ b/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs | |||
@@ -294,7 +294,7 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
294 | internal void waitForSpaceUnlock(IntPtr space) | 294 | internal void waitForSpaceUnlock(IntPtr space) |
295 | { | 295 | { |
296 | //if (space != (IntPtr)0) | 296 | //if (space != (IntPtr)0) |
297 | //while (d.SpaceLockQuery(space)){ } // Wait and do nothing | 297 | //while (d.SpaceLockQuery(space)) { } // Wait and do nothing |
298 | } | 298 | } |
299 | 299 | ||
300 | /// <summary> | 300 | /// <summary> |
@@ -952,7 +952,7 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
952 | 952 | ||
953 | public void addCollisionEventReporting(PhysicsActor obj) | 953 | public void addCollisionEventReporting(PhysicsActor obj) |
954 | { | 954 | { |
955 | lock(_collisionEventPrim) | 955 | lock (_collisionEventPrim) |
956 | { | 956 | { |
957 | if (!_collisionEventPrim.Contains(obj)) | 957 | if (!_collisionEventPrim.Contains(obj)) |
958 | _collisionEventPrim.Add(obj); | 958 | _collisionEventPrim.Add(obj); |
diff --git a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs index da30535..2233913 100644 --- a/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs +++ b/OpenSim/Region/ScriptEngine/Common/ScriptEngineBase/ScriptManager.cs | |||
@@ -207,7 +207,8 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase | |||
207 | 207 | ||
208 | public void DoScriptLoadUnload() | 208 | public void DoScriptLoadUnload() |
209 | { | 209 | { |
210 | lock (LUQueue) { | 210 | lock (LUQueue) |
211 | { | ||
211 | if (LUQueue.Count > 0) | 212 | if (LUQueue.Count > 0) |
212 | { | 213 | { |
213 | LUStruct item = LUQueue.Dequeue(); | 214 | LUStruct item = LUQueue.Dequeue(); |
@@ -216,7 +217,7 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase | |||
216 | { | 217 | { |
217 | _StopScript(item.localID, item.itemID); | 218 | _StopScript(item.localID, item.itemID); |
218 | } | 219 | } |
219 | if (item.Action == LUType.Load) | 220 | else if (item.Action == LUType.Load) |
220 | { | 221 | { |
221 | _StartScript(item.localID, item.itemID, item.script); | 222 | _StartScript(item.localID, item.itemID, item.script); |
222 | } | 223 | } |
@@ -249,7 +250,8 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase | |||
249 | /// <param name="localID"></param> | 250 | /// <param name="localID"></param> |
250 | public void StartScript(uint localID, LLUUID itemID, string Script) | 251 | public void StartScript(uint localID, LLUUID itemID, string Script) |
251 | { | 252 | { |
252 | lock(LUQueue) { | 253 | lock (LUQueue) |
254 | { | ||
253 | if (LUQueue.Count >= LoadUnloadMaxQueueSize) | 255 | if (LUQueue.Count >= LoadUnloadMaxQueueSize) |
254 | { | 256 | { |
255 | m_scriptEngine.Log.Error("[" + m_scriptEngine.ScriptEngineName + "]: ERROR: Load/unload queue item count is at " + LUQueue.Count + ". Config variable \"LoadUnloadMaxQueueSize\" is set to " + LoadUnloadMaxQueueSize + ", so ignoring new script."); | 257 | m_scriptEngine.Log.Error("[" + m_scriptEngine.ScriptEngineName + "]: ERROR: Load/unload queue item count is at " + LUQueue.Count + ". Config variable \"LoadUnloadMaxQueueSize\" is set to " + LoadUnloadMaxQueueSize + ", so ignoring new script."); |
@@ -276,7 +278,8 @@ namespace OpenSim.Region.ScriptEngine.Common.ScriptEngineBase | |||
276 | ls.localID = localID; | 278 | ls.localID = localID; |
277 | ls.itemID = itemID; | 279 | ls.itemID = itemID; |
278 | ls.Action = LUType.Unload; | 280 | ls.Action = LUType.Unload; |
279 | lock (LUQueue) { | 281 | lock (LUQueue) |
282 | { | ||
280 | LUQueue.Enqueue(ls); | 283 | LUQueue.Enqueue(ls); |
281 | } | 284 | } |
282 | } | 285 | } |
diff --git a/OpenSim/Region/ScriptEngine/LSOEngine/LSO/LSO_Enums.cs b/OpenSim/Region/ScriptEngine/LSOEngine/LSO/LSO_Enums.cs index 7b4a1af..c721267 100644 --- a/OpenSim/Region/ScriptEngine/LSOEngine/LSO/LSO_Enums.cs +++ b/OpenSim/Region/ScriptEngine/LSOEngine/LSO/LSO_Enums.cs | |||
@@ -34,7 +34,8 @@ namespace OpenSim.Region.ScriptEngine.LSOEngine.LSO | |||
34 | { | 34 | { |
35 | //public System.Collections.Generic.Dictionary<Byte, Type> OpCode_Add_Types; | 35 | //public System.Collections.Generic.Dictionary<Byte, Type> OpCode_Add_Types; |
36 | 36 | ||
37 | //LSO_Enums() { | 37 | //LSO_Enums() |
38 | //{ | ||
38 | // OpCode_Add_Types.Add(51, typeof(String)); | 39 | // OpCode_Add_Types.Add(51, typeof(String)); |
39 | // OpCode_Add_Types.Add(17, typeof(UInt32)); | 40 | // OpCode_Add_Types.Add(17, typeof(UInt32)); |
40 | //} | 41 | //} |