diff options
author | BlueWall | 2011-01-27 08:53:57 -0500 |
---|---|---|
committer | BlueWall | 2011-01-27 08:53:57 -0500 |
commit | d89d9d1b1310d494fbb7712057eab8a196e10a04 (patch) | |
tree | 62834b7f5954aa8f013a159ee2fc3ccee385e673 /OpenSim/Region/CoreModules | |
parent | Make FireAndForgetWrapper a singleton class (diff) | |
parent | Make it work (diff) | |
download | opensim-SC_OLD-d89d9d1b1310d494fbb7712057eab8a196e10a04.zip opensim-SC_OLD-d89d9d1b1310d494fbb7712057eab8a196e10a04.tar.gz opensim-SC_OLD-d89d9d1b1310d494fbb7712057eab8a196e10a04.tar.bz2 opensim-SC_OLD-d89d9d1b1310d494fbb7712057eab8a196e10a04.tar.xz |
Merge branch 'master' of /home/opensim/src/OpenSim/Core
Diffstat (limited to 'OpenSim/Region/CoreModules')
18 files changed, 209 insertions, 96 deletions
diff --git a/OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs b/OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs index c66a4ea..771038e 100644 --- a/OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs +++ b/OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs | |||
@@ -41,8 +41,8 @@ namespace OpenSim.Region.CoreModules.Agent.AssetTransaction | |||
41 | /// </summary> | 41 | /// </summary> |
42 | public class AgentAssetTransactions | 42 | public class AgentAssetTransactions |
43 | { | 43 | { |
44 | private static readonly ILog m_log = LogManager.GetLogger( | 44 | // private static readonly ILog m_log = LogManager.GetLogger( |
45 | MethodBase.GetCurrentMethod().DeclaringType); | 45 | // MethodBase.GetCurrentMethod().DeclaringType); |
46 | 46 | ||
47 | // Fields | 47 | // Fields |
48 | private bool m_dumpAssetsToFile; | 48 | private bool m_dumpAssetsToFile; |
diff --git a/OpenSim/Region/CoreModules/Avatar/Assets/GetMeshModule.cs b/OpenSim/Region/CoreModules/Avatar/Assets/GetMeshModule.cs index 36aaab3..878242a 100644 --- a/OpenSim/Region/CoreModules/Avatar/Assets/GetMeshModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Assets/GetMeshModule.cs | |||
@@ -49,8 +49,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Assets | |||
49 | [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] | 49 | [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] |
50 | public class GetMeshModule : INonSharedRegionModule | 50 | public class GetMeshModule : INonSharedRegionModule |
51 | { | 51 | { |
52 | private static readonly ILog m_log = | 52 | // private static readonly ILog m_log = |
53 | LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 53 | // LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
54 | |||
54 | private Scene m_scene; | 55 | private Scene m_scene; |
55 | private IAssetService m_assetService; | 56 | private IAssetService m_assetService; |
56 | 57 | ||
@@ -102,7 +103,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Assets | |||
102 | { | 103 | { |
103 | UUID capID = UUID.Random(); | 104 | UUID capID = UUID.Random(); |
104 | 105 | ||
105 | m_log.Info("[GETMESH]: /CAPS/" + capID); | 106 | // m_log.Info("[GETMESH]: /CAPS/" + capID); |
106 | caps.RegisterHandler("GetMesh", | 107 | caps.RegisterHandler("GetMesh", |
107 | new RestHTTPHandler("GET", "/CAPS/" + capID, | 108 | new RestHTTPHandler("GET", "/CAPS/" + capID, |
108 | delegate(Hashtable m_dhttpMethod) | 109 | delegate(Hashtable m_dhttpMethod) |
diff --git a/OpenSim/Region/CoreModules/Avatar/Assets/GetTextureModule.cs b/OpenSim/Region/CoreModules/Avatar/Assets/GetTextureModule.cs index 1f60e36..6fb8b46 100644 --- a/OpenSim/Region/CoreModules/Avatar/Assets/GetTextureModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Assets/GetTextureModule.cs | |||
@@ -105,7 +105,7 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
105 | { | 105 | { |
106 | UUID capID = UUID.Random(); | 106 | UUID capID = UUID.Random(); |
107 | 107 | ||
108 | m_log.InfoFormat("[GETTEXTURE]: /CAPS/{0} in region {1}", capID, m_scene.RegionInfo.RegionName); | 108 | // m_log.InfoFormat("[GETTEXTURE]: /CAPS/{0} in region {1}", capID, m_scene.RegionInfo.RegionName); |
109 | caps.RegisterHandler("GetTexture", new StreamHandler("GET", "/CAPS/" + capID, ProcessGetTexture)); | 109 | caps.RegisterHandler("GetTexture", new StreamHandler("GET", "/CAPS/" + capID, ProcessGetTexture)); |
110 | } | 110 | } |
111 | 111 | ||
@@ -171,7 +171,7 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
171 | /// <returns>False for "caller try another codec"; true otherwise</returns> | 171 | /// <returns>False for "caller try another codec"; true otherwise</returns> |
172 | private bool FetchTexture(OSHttpRequest httpRequest, OSHttpResponse httpResponse, UUID textureID, string format) | 172 | private bool FetchTexture(OSHttpRequest httpRequest, OSHttpResponse httpResponse, UUID textureID, string format) |
173 | { | 173 | { |
174 | m_log.DebugFormat("[GETTEXTURE]: {0} with requested format {1}", textureID, format); | 174 | // m_log.DebugFormat("[GETTEXTURE]: {0} with requested format {1}", textureID, format); |
175 | AssetBase texture; | 175 | AssetBase texture; |
176 | 176 | ||
177 | string fullID = textureID.ToString(); | 177 | string fullID = textureID.ToString(); |
diff --git a/OpenSim/Region/CoreModules/Avatar/Assets/NewFileAgentInventoryVariablePriceModule.cs b/OpenSim/Region/CoreModules/Avatar/Assets/NewFileAgentInventoryVariablePriceModule.cs index af26b2b..542af25 100644 --- a/OpenSim/Region/CoreModules/Avatar/Assets/NewFileAgentInventoryVariablePriceModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Assets/NewFileAgentInventoryVariablePriceModule.cs | |||
@@ -50,8 +50,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Assets | |||
50 | [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] | 50 | [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] |
51 | public class NewFileAgentInventoryVariablePriceModule : INonSharedRegionModule | 51 | public class NewFileAgentInventoryVariablePriceModule : INonSharedRegionModule |
52 | { | 52 | { |
53 | private static readonly ILog m_log = | 53 | // private static readonly ILog m_log = |
54 | LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 54 | // LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
55 | |||
55 | private Scene m_scene; | 56 | private Scene m_scene; |
56 | private IAssetService m_assetService; | 57 | private IAssetService m_assetService; |
57 | private bool m_dumpAssetsToFile = false; | 58 | private bool m_dumpAssetsToFile = false; |
@@ -104,7 +105,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Assets | |||
104 | { | 105 | { |
105 | UUID capID = UUID.Random(); | 106 | UUID capID = UUID.Random(); |
106 | 107 | ||
107 | m_log.Info("[GETMESH]: /CAPS/" + capID); | 108 | // m_log.Debug("[NEW FILE AGENT INVENTORY VARIABLE PRICE]: /CAPS/" + capID); |
108 | caps.RegisterHandler("NewFileAgentInventoryVariablePrice", | 109 | caps.RegisterHandler("NewFileAgentInventoryVariablePrice", |
109 | 110 | ||
110 | new LLSDStreamhandler<LLSDAssetUploadRequest, LLSDNewFileAngentInventoryVariablePriceReplyResponse>("POST", | 111 | new LLSDStreamhandler<LLSDAssetUploadRequest, LLSDNewFileAngentInventoryVariablePriceReplyResponse>("POST", |
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs index 360a014..ff26264 100644 --- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | |||
@@ -132,8 +132,6 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
132 | "[ATTACHMENTS MODULE]: Saving avatar attachment. AgentID: " + remoteClient.AgentId | 132 | "[ATTACHMENTS MODULE]: Saving avatar attachment. AgentID: " + remoteClient.AgentId |
133 | + ", AttachmentPoint: " + AttachmentPt); | 133 | + ", AttachmentPoint: " + AttachmentPt); |
134 | 134 | ||
135 | if (m_scene.AvatarFactory != null) | ||
136 | m_scene.AvatarFactory.QueueAppearanceSave(remoteClient.AgentId); | ||
137 | } | 135 | } |
138 | } | 136 | } |
139 | catch (Exception e) | 137 | catch (Exception e) |
@@ -336,7 +334,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
336 | InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId); | 334 | InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId); |
337 | item = m_scene.InventoryService.GetItem(item); | 335 | item = m_scene.InventoryService.GetItem(item); |
338 | 336 | ||
339 | presence.Appearance.SetAttachment((int)AttachmentPt, itemID, item.AssetID /*att.UUID*/); | 337 | bool changed = presence.Appearance.SetAttachment((int)AttachmentPt, itemID, item.AssetID); |
338 | if (changed && m_scene.AvatarFactory != null) | ||
339 | m_scene.AvatarFactory.QueueAppearanceSave(remoteClient.AgentId); | ||
340 | } | 340 | } |
341 | 341 | ||
342 | return att.UUID; | 342 | return att.UUID; |
@@ -380,9 +380,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
380 | // XXYY!! | 380 | // XXYY!! |
381 | InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId); | 381 | InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId); |
382 | item = m_scene.InventoryService.GetItem(item); | 382 | item = m_scene.InventoryService.GetItem(item); |
383 | presence.Appearance.SetAttachment((int)AttachmentPt, itemID, item.AssetID /* att.UUID */); | 383 | bool changed = presence.Appearance.SetAttachment((int)AttachmentPt, itemID, item.AssetID); |
384 | 384 | if (changed && m_scene.AvatarFactory != null) | |
385 | if (m_scene.AvatarFactory != null) | ||
386 | m_scene.AvatarFactory.QueueAppearanceSave(remoteClient.AgentId); | 385 | m_scene.AvatarFactory.QueueAppearanceSave(remoteClient.AgentId); |
387 | } | 386 | } |
388 | } | 387 | } |
@@ -402,11 +401,11 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
402 | ScenePresence presence; | 401 | ScenePresence presence; |
403 | if (m_scene.TryGetScenePresence(remoteClient.AgentId, out presence)) | 402 | if (m_scene.TryGetScenePresence(remoteClient.AgentId, out presence)) |
404 | { | 403 | { |
405 | presence.Appearance.DetachAttachment(itemID); | ||
406 | |||
407 | // Save avatar attachment information | 404 | // Save avatar attachment information |
408 | m_log.Debug("[ATTACHMENTS MODULE]: Detaching from UserID: " + remoteClient.AgentId + ", ItemID: " + itemID); | 405 | m_log.Debug("[ATTACHMENTS MODULE]: Detaching from UserID: " + remoteClient.AgentId + ", ItemID: " + itemID); |
409 | if (m_scene.AvatarFactory != null) | 406 | |
407 | bool changed = presence.Appearance.DetachAttachment(itemID); | ||
408 | if (changed && m_scene.AvatarFactory != null) | ||
410 | m_scene.AvatarFactory.QueueAppearanceSave(remoteClient.AgentId); | 409 | m_scene.AvatarFactory.QueueAppearanceSave(remoteClient.AgentId); |
411 | } | 410 | } |
412 | 411 | ||
@@ -431,9 +430,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
431 | part.ParentGroup.PrimCount, remoteClient.AgentId, presence.AbsolutePosition)) | 430 | part.ParentGroup.PrimCount, remoteClient.AgentId, presence.AbsolutePosition)) |
432 | return; | 431 | return; |
433 | 432 | ||
434 | presence.Appearance.DetachAttachment(itemID); | 433 | bool changed = presence.Appearance.DetachAttachment(itemID); |
435 | 434 | if (changed && m_scene.AvatarFactory != null) | |
436 | if (m_scene.AvatarFactory != null) | ||
437 | m_scene.AvatarFactory.QueueAppearanceSave(remoteClient.AgentId); | 435 | m_scene.AvatarFactory.QueueAppearanceSave(remoteClient.AgentId); |
438 | 436 | ||
439 | part.ParentGroup.DetachToGround(); | 437 | part.ParentGroup.DetachToGround(); |
diff --git a/OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs b/OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs index 7d6d191..f8ce444 100644 --- a/OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs | |||
@@ -167,7 +167,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory | |||
167 | } | 167 | } |
168 | } | 168 | } |
169 | 169 | ||
170 | m_log.InfoFormat("[AVFACTORY]: complete texture check for {0}",client.AgentId); | 170 | m_log.InfoFormat("[AVFACTORY]: complete texture check for {0}", client.AgentId); |
171 | 171 | ||
172 | // If we only found default textures, then the appearance is not cached | 172 | // If we only found default textures, then the appearance is not cached |
173 | return (defonly ? false : true); | 173 | return (defonly ? false : true); |
@@ -187,7 +187,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory | |||
187 | return; | 187 | return; |
188 | } | 188 | } |
189 | 189 | ||
190 | m_log.InfoFormat("[AVFACTORY]: start SetAppearance for {0}",client.AgentId); | 190 | // m_log.InfoFormat("[AVFACTORY]: start SetAppearance for {0}", client.AgentId); |
191 | 191 | ||
192 | // TODO: This is probably not necessary any longer, just assume the | 192 | // TODO: This is probably not necessary any longer, just assume the |
193 | // textureEntry set implies that the appearance transaction is complete | 193 | // textureEntry set implies that the appearance transaction is complete |
@@ -210,14 +210,16 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory | |||
210 | { | 210 | { |
211 | changed = sp.Appearance.SetTextureEntries(textureEntry) || changed; | 211 | changed = sp.Appearance.SetTextureEntries(textureEntry) || changed; |
212 | 212 | ||
213 | m_log.InfoFormat("[AVFACTORY]: received texture update for {0}",client.AgentId); | 213 | m_log.InfoFormat("[AVFACTORY]: received texture update for {0}", client.AgentId); |
214 | Util.FireAndForget(delegate(object o) { ValidateBakedTextureCache(client,false); }); | 214 | Util.FireAndForget(delegate(object o) { ValidateBakedTextureCache(client,false); }); |
215 | 215 | ||
216 | // This appears to be set only in the final stage of the appearance | 216 | // This appears to be set only in the final stage of the appearance |
217 | // update transaction. In theory, we should be able to do an immediate | 217 | // update transaction. In theory, we should be able to do an immediate |
218 | // appearance send and save here. | 218 | // appearance send and save here. |
219 | 219 | ||
220 | QueueAppearanceSave(client.AgentId); | 220 | // save only if there were changes, send no matter what (doesn't hurt to send twice) |
221 | if (changed) | ||
222 | QueueAppearanceSave(client.AgentId); | ||
221 | QueueAppearanceSend(client.AgentId); | 223 | QueueAppearanceSend(client.AgentId); |
222 | } | 224 | } |
223 | 225 | ||
diff --git a/OpenSim/Region/CoreModules/Avatar/Gestures/GesturesModule.cs b/OpenSim/Region/CoreModules/Avatar/Gestures/GesturesModule.cs index 7303fe7..7df2beb 100644 --- a/OpenSim/Region/CoreModules/Avatar/Gestures/GesturesModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Gestures/GesturesModule.cs | |||
@@ -69,7 +69,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Gestures | |||
69 | item = invService.GetItem(item); | 69 | item = invService.GetItem(item); |
70 | if (item != null) | 70 | if (item != null) |
71 | { | 71 | { |
72 | item.Flags = 1; | 72 | item.Flags |= 1; |
73 | invService.UpdateItem(item); | 73 | invService.UpdateItem(item); |
74 | } | 74 | } |
75 | else | 75 | else |
@@ -85,7 +85,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Gestures | |||
85 | item = invService.GetItem(item); | 85 | item = invService.GetItem(item); |
86 | if (item != null) | 86 | if (item != null) |
87 | { | 87 | { |
88 | item.Flags = 0; | 88 | item.Flags &= ~(uint)1; |
89 | invService.UpdateItem(item); | 89 | invService.UpdateItem(item); |
90 | } | 90 | } |
91 | else | 91 | else |
@@ -93,4 +93,4 @@ namespace OpenSim.Region.CoreModules.Avatar.Gestures | |||
93 | "[GESTURES]: Unable to find gesture to deactivate {0} for {1}", gestureId, client.Name); | 93 | "[GESTURES]: Unable to find gesture to deactivate {0} for {1}", gestureId, client.Name); |
94 | } | 94 | } |
95 | } | 95 | } |
96 | } \ No newline at end of file | 96 | } |
diff --git a/OpenSim/Region/CoreModules/Avatar/InstantMessage/MessageTransferModule.cs b/OpenSim/Region/CoreModules/Avatar/InstantMessage/MessageTransferModule.cs index 21a61a7..77c7147 100644 --- a/OpenSim/Region/CoreModules/Avatar/InstantMessage/MessageTransferModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/InstantMessage/MessageTransferModule.cs | |||
@@ -146,7 +146,7 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage | |||
146 | if (!user.IsChildAgent) | 146 | if (!user.IsChildAgent) |
147 | { | 147 | { |
148 | // Local message | 148 | // Local message |
149 | m_log.DebugFormat("[INSTANT MESSAGE]: Delivering IM to root agent {0} {1}", user.Name, toAgentID); | 149 | // m_log.DebugFormat("[INSTANT MESSAGE]: Delivering IM to root agent {0} {1}", user.Name, toAgentID); |
150 | user.ControllingClient.SendInstantMessage(im); | 150 | user.ControllingClient.SendInstantMessage(im); |
151 | 151 | ||
152 | // Message sent | 152 | // Message sent |
@@ -168,7 +168,7 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage | |||
168 | // Local message | 168 | // Local message |
169 | ScenePresence user = (ScenePresence) scene.Entities[toAgentID]; | 169 | ScenePresence user = (ScenePresence) scene.Entities[toAgentID]; |
170 | 170 | ||
171 | m_log.DebugFormat("[INSTANT MESSAGE]: Delivering IM to child agent {0} {1}", user.Name, toAgentID); | 171 | // m_log.DebugFormat("[INSTANT MESSAGE]: Delivering IM to child agent {0} {1}", user.Name, toAgentID); |
172 | user.ControllingClient.SendInstantMessage(im); | 172 | user.ControllingClient.SendInstantMessage(im); |
173 | 173 | ||
174 | // Message sent | 174 | // Message sent |
@@ -177,7 +177,7 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage | |||
177 | } | 177 | } |
178 | } | 178 | } |
179 | 179 | ||
180 | m_log.DebugFormat("[INSTANT MESSAGE]: Delivering IM to {0} via XMLRPC", im.toAgentID); | 180 | // m_log.DebugFormat("[INSTANT MESSAGE]: Delivering IM to {0} via XMLRPC", im.toAgentID); |
181 | SendGridInstantMessageViaXMLRPC(im, result); | 181 | SendGridInstantMessageViaXMLRPC(im, result); |
182 | 182 | ||
183 | return; | 183 | return; |
diff --git a/OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs b/OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs index c011776..a0d72ed 100644 --- a/OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs +++ b/OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs | |||
@@ -43,8 +43,9 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
43 | { | 43 | { |
44 | public class ObjectAdd : IRegionModule | 44 | public class ObjectAdd : IRegionModule |
45 | { | 45 | { |
46 | private static readonly ILog m_log = | 46 | // private static readonly ILog m_log = |
47 | LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 47 | // LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
48 | |||
48 | private Scene m_scene; | 49 | private Scene m_scene; |
49 | #region IRegionModule Members | 50 | #region IRegionModule Members |
50 | 51 | ||
@@ -63,7 +64,7 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
63 | { | 64 | { |
64 | UUID capuuid = UUID.Random(); | 65 | UUID capuuid = UUID.Random(); |
65 | 66 | ||
66 | m_log.InfoFormat("[OBJECTADD]: {0}", "/CAPS/OA/" + capuuid + "/"); | 67 | // m_log.InfoFormat("[OBJECTADD]: {0}", "/CAPS/OA/" + capuuid + "/"); |
67 | 68 | ||
68 | caps.RegisterHandler("ObjectAdd", | 69 | caps.RegisterHandler("ObjectAdd", |
69 | new RestHTTPHandler("POST", "/CAPS/OA/" + capuuid + "/", | 70 | new RestHTTPHandler("POST", "/CAPS/OA/" + capuuid + "/", |
diff --git a/OpenSim/Region/CoreModules/Avatar/ObjectCaps/UploadObjectAssetModule.cs b/OpenSim/Region/CoreModules/Avatar/ObjectCaps/UploadObjectAssetModule.cs index 09b9719..3114d7f 100644 --- a/OpenSim/Region/CoreModules/Avatar/ObjectCaps/UploadObjectAssetModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/ObjectCaps/UploadObjectAssetModule.cs | |||
@@ -105,7 +105,7 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
105 | { | 105 | { |
106 | UUID capID = UUID.Random(); | 106 | UUID capID = UUID.Random(); |
107 | 107 | ||
108 | m_log.Info("[UploadObjectAssetModule]: /CAPS/" + capID); | 108 | // m_log.Debug("[UPLOAD OBJECT ASSET MODULE]: /CAPS/" + capID); |
109 | caps.RegisterHandler("UploadObjectAsset", | 109 | caps.RegisterHandler("UploadObjectAsset", |
110 | new RestHTTPHandler("POST", "/CAPS/OA/" + capID + "/", | 110 | new RestHTTPHandler("POST", "/CAPS/OA/" + capID + "/", |
111 | delegate(Hashtable m_dhttpMethod) | 111 | delegate(Hashtable m_dhttpMethod) |
@@ -156,7 +156,7 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
156 | } | 156 | } |
157 | catch (Exception ex) | 157 | catch (Exception ex) |
158 | { | 158 | { |
159 | m_log.Error("[UploadObjectAssetModule]: Error deserializing message " + ex.ToString()); | 159 | m_log.Error("[UPLOAD OBJECT ASSET MODULE]: Error deserializing message " + ex.ToString()); |
160 | message = null; | 160 | message = null; |
161 | } | 161 | } |
162 | 162 | ||
@@ -174,7 +174,7 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
174 | Vector3 pos = avatar.AbsolutePosition + (Vector3.UnitX * avatar.Rotation); | 174 | Vector3 pos = avatar.AbsolutePosition + (Vector3.UnitX * avatar.Rotation); |
175 | Quaternion rot = Quaternion.Identity; | 175 | Quaternion rot = Quaternion.Identity; |
176 | Vector3 rootpos = Vector3.Zero; | 176 | Vector3 rootpos = Vector3.Zero; |
177 | Quaternion rootrot = Quaternion.Identity; | 177 | // Quaternion rootrot = Quaternion.Identity; |
178 | 178 | ||
179 | SceneObjectGroup rootGroup = null; | 179 | SceneObjectGroup rootGroup = null; |
180 | SceneObjectGroup[] allparts = new SceneObjectGroup[message.Objects.Length]; | 180 | SceneObjectGroup[] allparts = new SceneObjectGroup[message.Objects.Length]; |
@@ -186,11 +186,9 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
186 | if (i == 0) | 186 | if (i == 0) |
187 | { | 187 | { |
188 | rootpos = obj.Position; | 188 | rootpos = obj.Position; |
189 | rootrot = obj.Rotation; | 189 | // rootrot = obj.Rotation; |
190 | |||
191 | } | 190 | } |
192 | 191 | ||
193 | |||
194 | // Combine the extraparams data into it's ugly blob again.... | 192 | // Combine the extraparams data into it's ugly blob again.... |
195 | //int bytelength = 0; | 193 | //int bytelength = 0; |
196 | //for (int extparams = 0; extparams < obj.ExtraParams.Length; extparams++) | 194 | //for (int extparams = 0; extparams < obj.ExtraParams.Length; extparams++) |
@@ -363,9 +361,8 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
363 | responsedata["str_response_string"] = String.Format("<llsd><map><key>local_id</key>{0}</map></llsd>", ConvertUintToBytes(allparts[0].LocalId)); | 361 | responsedata["str_response_string"] = String.Format("<llsd><map><key>local_id</key>{0}</map></llsd>", ConvertUintToBytes(allparts[0].LocalId)); |
364 | 362 | ||
365 | return responsedata; | 363 | return responsedata; |
366 | |||
367 | |||
368 | } | 364 | } |
365 | |||
369 | private string ConvertUintToBytes(uint val) | 366 | private string ConvertUintToBytes(uint val) |
370 | { | 367 | { |
371 | byte[] resultbytes = Utils.UIntToBytes(val); | 368 | byte[] resultbytes = Utils.UIntToBytes(val); |
@@ -374,4 +371,4 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps | |||
374 | return String.Format("<binary encoding=\"base64\">{0}</binary>", Convert.ToBase64String(resultbytes)); | 371 | return String.Format("<binary encoding=\"base64\">{0}</binary>", Convert.ToBase64String(resultbytes)); |
375 | } | 372 | } |
376 | } | 373 | } |
377 | } | 374 | } \ No newline at end of file |
diff --git a/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs b/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs index ddae20f..b0563c5 100644 --- a/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs +++ b/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs | |||
@@ -767,6 +767,7 @@ namespace OpenSim.Region.CoreModules.World.Estate | |||
767 | LookupUUIDS icon = (LookupUUIDS)iar.AsyncState; | 767 | LookupUUIDS icon = (LookupUUIDS)iar.AsyncState; |
768 | icon.EndInvoke(iar); | 768 | icon.EndInvoke(iar); |
769 | } | 769 | } |
770 | |||
770 | private void LookupUUID(List<UUID> uuidLst) | 771 | private void LookupUUID(List<UUID> uuidLst) |
771 | { | 772 | { |
772 | LookupUUIDS d = LookupUUIDsAsync; | 773 | LookupUUIDS d = LookupUUIDsAsync; |
@@ -775,6 +776,7 @@ namespace OpenSim.Region.CoreModules.World.Estate | |||
775 | LookupUUIDSCompleted, | 776 | LookupUUIDSCompleted, |
776 | d); | 777 | d); |
777 | } | 778 | } |
779 | |||
778 | private void LookupUUIDsAsync(List<UUID> uuidLst) | 780 | private void LookupUUIDsAsync(List<UUID> uuidLst) |
779 | { | 781 | { |
780 | UUID[] uuidarr; | 782 | UUID[] uuidarr; |
@@ -789,12 +791,12 @@ namespace OpenSim.Region.CoreModules.World.Estate | |||
789 | // string lookupname = m_scene.CommsManager.UUIDNameRequestString(uuidarr[i]); | 791 | // string lookupname = m_scene.CommsManager.UUIDNameRequestString(uuidarr[i]); |
790 | 792 | ||
791 | IUserManagement userManager = m_scene.RequestModuleInterface<IUserManagement>(); | 793 | IUserManagement userManager = m_scene.RequestModuleInterface<IUserManagement>(); |
792 | string userName = "Unkown User"; | ||
793 | if (userManager != null) | 794 | if (userManager != null) |
794 | userName = userManager.GetUserName(uuidarr[i]); | 795 | userManager.GetUserName(uuidarr[i]); |
795 | 796 | ||
796 | // we drop it. It gets cached though... so we're ready for the next request. | 797 | // we drop it. It gets cached though... so we're ready for the next request. |
797 | // diva commnent 11/21/2010: uh?!? wft? | 798 | // diva commnent 11/21/2010: uh?!? wft? |
799 | // justincc comment 21/01/2011: A side effect of userManager.GetUserName() I presume. | ||
798 | } | 800 | } |
799 | } | 801 | } |
800 | #endregion | 802 | #endregion |
diff --git a/OpenSim/Region/CoreModules/World/Land/LandChannel.cs b/OpenSim/Region/CoreModules/World/Land/LandChannel.cs index 1ad4db2..9e27ef0 100644 --- a/OpenSim/Region/CoreModules/World/Land/LandChannel.cs +++ b/OpenSim/Region/CoreModules/World/Land/LandChannel.cs | |||
@@ -64,7 +64,7 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
64 | #endregion | 64 | #endregion |
65 | 65 | ||
66 | private readonly Scene m_scene; | 66 | private readonly Scene m_scene; |
67 | private readonly LandManagementModule m_landManagementModule; | 67 | private readonly LandManagementModule m_landManagementModule; |
68 | 68 | ||
69 | public LandChannel(Scene scene, LandManagementModule landManagementMod) | 69 | public LandChannel(Scene scene, LandManagementModule landManagementMod) |
70 | { | 70 | { |
diff --git a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs index 4f8e205..70767f7 100644 --- a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs +++ b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs | |||
@@ -30,6 +30,7 @@ using System.Collections; | |||
30 | using System.Collections.Generic; | 30 | using System.Collections.Generic; |
31 | using System.Diagnostics; | 31 | using System.Diagnostics; |
32 | using System.Reflection; | 32 | using System.Reflection; |
33 | using System.Text; | ||
33 | using log4net; | 34 | using log4net; |
34 | using Nini.Config; | 35 | using Nini.Config; |
35 | using OpenMetaverse; | 36 | using OpenMetaverse; |
@@ -37,19 +38,22 @@ using OpenMetaverse.StructuredData; | |||
37 | using OpenMetaverse.Messages.Linden; | 38 | using OpenMetaverse.Messages.Linden; |
38 | using OpenSim.Framework; | 39 | using OpenSim.Framework; |
39 | using OpenSim.Framework.Capabilities; | 40 | using OpenSim.Framework.Capabilities; |
41 | using OpenSim.Framework.Console; | ||
40 | using OpenSim.Framework.Servers; | 42 | using OpenSim.Framework.Servers; |
41 | using OpenSim.Framework.Servers.HttpServer; | 43 | using OpenSim.Framework.Servers.HttpServer; |
42 | using OpenSim.Services.Interfaces; | 44 | using OpenSim.Region.CoreModules.Framework.InterfaceCommander; |
43 | using OpenSim.Region.Framework.Interfaces; | 45 | using OpenSim.Region.Framework.Interfaces; |
44 | using OpenSim.Region.Framework.Scenes; | 46 | using OpenSim.Region.Framework.Scenes; |
45 | using OpenSim.Region.Physics.Manager; | 47 | using OpenSim.Region.Physics.Manager; |
46 | using Caps=OpenSim.Framework.Capabilities.Caps; | 48 | using OpenSim.Services.Interfaces; |
49 | using Caps = OpenSim.Framework.Capabilities.Caps; | ||
47 | using GridRegion = OpenSim.Services.Interfaces.GridRegion; | 50 | using GridRegion = OpenSim.Services.Interfaces.GridRegion; |
48 | 51 | ||
49 | namespace OpenSim.Region.CoreModules.World.Land | 52 | namespace OpenSim.Region.CoreModules.World.Land |
50 | { | 53 | { |
51 | // used for caching | 54 | // used for caching |
52 | internal class ExtendedLandData { | 55 | internal class ExtendedLandData |
56 | { | ||
53 | public LandData LandData; | 57 | public LandData LandData; |
54 | public ulong RegionHandle; | 58 | public ulong RegionHandle; |
55 | public uint X, Y; | 59 | public uint X, Y; |
@@ -65,6 +69,9 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
65 | 69 | ||
66 | private LandChannel landChannel; | 70 | private LandChannel landChannel; |
67 | private Scene m_scene; | 71 | private Scene m_scene; |
72 | protected Commander m_commander = new Commander("land"); | ||
73 | |||
74 | protected IUserManagement m_userManager; | ||
68 | 75 | ||
69 | // Minimum for parcels to work is 64m even if we don't actually use them. | 76 | // Minimum for parcels to work is 64m even if we don't actually use them. |
70 | #pragma warning disable 0429 | 77 | #pragma warning disable 0429 |
@@ -127,19 +134,27 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
127 | m_scene.EventManager.OnRequestParcelPrimCountUpdate += EventManagerOnRequestParcelPrimCountUpdate; | 134 | m_scene.EventManager.OnRequestParcelPrimCountUpdate += EventManagerOnRequestParcelPrimCountUpdate; |
128 | m_scene.EventManager.OnParcelPrimCountTainted += EventManagerOnParcelPrimCountTainted; | 135 | m_scene.EventManager.OnParcelPrimCountTainted += EventManagerOnParcelPrimCountTainted; |
129 | m_scene.EventManager.OnRegisterCaps += EventManagerOnRegisterCaps; | 136 | m_scene.EventManager.OnRegisterCaps += EventManagerOnRegisterCaps; |
137 | m_scene.EventManager.OnPluginConsole += EventManagerOnPluginConsole; | ||
130 | 138 | ||
131 | lock (m_scene) | 139 | lock (m_scene) |
132 | { | 140 | { |
133 | m_scene.LandChannel = (ILandChannel)landChannel; | 141 | m_scene.LandChannel = (ILandChannel)landChannel; |
134 | } | 142 | } |
143 | |||
144 | InstallInterfaces(); | ||
135 | } | 145 | } |
136 | 146 | ||
137 | public void RegionLoaded(Scene scene) | 147 | public void RegionLoaded(Scene scene) |
138 | { | 148 | { |
149 | m_userManager = m_scene.RequestModuleInterface<IUserManagement>(); | ||
139 | } | 150 | } |
140 | 151 | ||
141 | public void RemoveRegion(Scene scene) | 152 | public void RemoveRegion(Scene scene) |
142 | { | 153 | { |
154 | // TODO: Also release other event manager listeners here | ||
155 | |||
156 | m_scene.EventManager.OnPluginConsole -= EventManagerOnPluginConsole; | ||
157 | m_scene.UnregisterModuleCommander(m_commander.Name); | ||
143 | } | 158 | } |
144 | 159 | ||
145 | // private bool OnVerifyUserConnection(ScenePresence scenePresence, out string reason) | 160 | // private bool OnVerifyUserConnection(ScenePresence scenePresence, out string reason) |
@@ -148,6 +163,29 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
148 | // reason = "You are not allowed to enter this sim."; | 163 | // reason = "You are not allowed to enter this sim."; |
149 | // return nearestParcel != null; | 164 | // return nearestParcel != null; |
150 | // } | 165 | // } |
166 | |||
167 | /// <summary> | ||
168 | /// Processes commandline input. Do not call directly. | ||
169 | /// </summary> | ||
170 | /// <param name="args">Commandline arguments</param> | ||
171 | protected void EventManagerOnPluginConsole(string[] args) | ||
172 | { | ||
173 | if (args[0] == "land") | ||
174 | { | ||
175 | if (args.Length == 1) | ||
176 | { | ||
177 | m_commander.ProcessConsoleCommand("help", new string[0]); | ||
178 | return; | ||
179 | } | ||
180 | |||
181 | string[] tmpArgs = new string[args.Length - 2]; | ||
182 | int i; | ||
183 | for (i = 2; i < args.Length; i++) | ||
184 | tmpArgs[i - 2] = args[i]; | ||
185 | |||
186 | m_commander.ProcessConsoleCommand(args[1], tmpArgs); | ||
187 | } | ||
188 | } | ||
151 | 189 | ||
152 | void EventManagerOnNewClient(IClientAPI client) | 190 | void EventManagerOnNewClient(IClientAPI client) |
153 | { | 191 | { |
@@ -209,11 +247,6 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
209 | } | 247 | } |
210 | } | 248 | } |
211 | 249 | ||
212 | |||
213 | public void PostInitialise() | ||
214 | { | ||
215 | } | ||
216 | |||
217 | public void Close() | 250 | public void Close() |
218 | { | 251 | { |
219 | } | 252 | } |
@@ -223,11 +256,6 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
223 | get { return "LandManagementModule"; } | 256 | get { return "LandManagementModule"; } |
224 | } | 257 | } |
225 | 258 | ||
226 | public bool IsSharedModule | ||
227 | { | ||
228 | get { return false; } | ||
229 | } | ||
230 | |||
231 | #endregion | 259 | #endregion |
232 | 260 | ||
233 | #region Parcel Add/Remove/Get/Create | 261 | #region Parcel Add/Remove/Get/Create |
@@ -1591,5 +1619,44 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
1591 | 1619 | ||
1592 | UpdateLandObject(localID, land.LandData); | 1620 | UpdateLandObject(localID, land.LandData); |
1593 | } | 1621 | } |
1622 | |||
1623 | protected void InstallInterfaces() | ||
1624 | { | ||
1625 | Command showCommand = | ||
1626 | new Command("show", CommandIntentions.COMMAND_STATISTICAL, ShowParcelsCommand, "Shows all parcels on the current region."); | ||
1627 | |||
1628 | m_commander.RegisterCommand("show", showCommand); | ||
1629 | |||
1630 | // Add this to our scene so scripts can call these functions | ||
1631 | m_scene.RegisterModuleCommander(m_commander); | ||
1632 | } | ||
1633 | |||
1634 | protected void ShowParcelsCommand(Object[] args) | ||
1635 | { | ||
1636 | StringBuilder report = new StringBuilder(); | ||
1637 | |||
1638 | report.AppendFormat("Land information for {0}\n", m_scene.RegionInfo.RegionName); | ||
1639 | report.AppendFormat( | ||
1640 | "{0,-20} {1,-9} {2,-18} {3,-18} {4,-20}\n", | ||
1641 | "Parcel Name", | ||
1642 | "Area", | ||
1643 | "Starts", | ||
1644 | "Ends", | ||
1645 | "Owner"); | ||
1646 | |||
1647 | lock (m_landList) | ||
1648 | { | ||
1649 | foreach (ILandObject lo in m_landList.Values) | ||
1650 | { | ||
1651 | LandData ld = lo.LandData; | ||
1652 | |||
1653 | report.AppendFormat( | ||
1654 | "{0,-20} {1,-9} {2,-18} {3,-18} {4,-20}\n", | ||
1655 | ld.Name, ld.Area, lo.StartPoint, lo.EndPoint, m_userManager.GetUserName(ld.OwnerID)); | ||
1656 | } | ||
1657 | } | ||
1658 | |||
1659 | MainConsole.Instance.Output(report.ToString()); | ||
1660 | } | ||
1594 | } | 1661 | } |
1595 | } | 1662 | } \ No newline at end of file |
diff --git a/OpenSim/Region/CoreModules/World/Land/LandObject.cs b/OpenSim/Region/CoreModules/World/Land/LandObject.cs index 3e41c55..b90e307 100644 --- a/OpenSim/Region/CoreModules/World/Land/LandObject.cs +++ b/OpenSim/Region/CoreModules/World/Land/LandObject.cs | |||
@@ -77,7 +77,43 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
77 | { | 77 | { |
78 | get { return m_scene.RegionInfo.RegionID; } | 78 | get { return m_scene.RegionInfo.RegionID; } |
79 | } | 79 | } |
80 | 80 | ||
81 | public Vector3 StartPoint | ||
82 | { | ||
83 | get | ||
84 | { | ||
85 | for (int y = 0; y < landArrayMax; y++) | ||
86 | { | ||
87 | for (int x = 0; x < landArrayMax; x++) | ||
88 | { | ||
89 | if (LandBitmap[x, y]) | ||
90 | return new Vector3(x * 4, y * 4, 0); | ||
91 | } | ||
92 | } | ||
93 | |||
94 | return new Vector3(-1, -1, -1); | ||
95 | } | ||
96 | } | ||
97 | |||
98 | public Vector3 EndPoint | ||
99 | { | ||
100 | get | ||
101 | { | ||
102 | for (int y = landArrayMax - 1; y >= 0; y--) | ||
103 | { | ||
104 | for (int x = landArrayMax - 1; x >= 0; x--) | ||
105 | { | ||
106 | if (LandBitmap[x, y]) | ||
107 | { | ||
108 | return new Vector3(x * 4, y * 4, 0); | ||
109 | } | ||
110 | } | ||
111 | } | ||
112 | |||
113 | return new Vector3(-1, -1, -1); | ||
114 | } | ||
115 | } | ||
116 | |||
81 | #region Constructors | 117 | #region Constructors |
82 | 118 | ||
83 | public LandObject(UUID owner_id, bool is_group_owned, Scene scene) | 119 | public LandObject(UUID owner_id, bool is_group_owned, Scene scene) |
@@ -96,7 +132,7 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
96 | #region Member Functions | 132 | #region Member Functions |
97 | 133 | ||
98 | #region General Functions | 134 | #region General Functions |
99 | 135 | ||
100 | /// <summary> | 136 | /// <summary> |
101 | /// Checks to see if this land object contains a point | 137 | /// Checks to see if this land object contains a point |
102 | /// </summary> | 138 | /// </summary> |
@@ -217,6 +253,7 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
217 | ParcelFlags.AllowDamage | | 253 | ParcelFlags.AllowDamage | |
218 | ParcelFlags.CreateObjects | | 254 | ParcelFlags.CreateObjects | |
219 | ParcelFlags.RestrictPushObject | | 255 | ParcelFlags.RestrictPushObject | |
256 | ParcelFlags.AllowOtherScripts | | ||
220 | ParcelFlags.AllowGroupScripts | | 257 | ParcelFlags.AllowGroupScripts | |
221 | ParcelFlags.CreateGroupObjects | | 258 | ParcelFlags.CreateGroupObjects | |
222 | ParcelFlags.AllowAPrimitiveEntry | | 259 | ParcelFlags.AllowAPrimitiveEntry | |
diff --git a/OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs b/OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs index ec97acd..0e861a1 100644 --- a/OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs +++ b/OpenSim/Region/CoreModules/World/Serialiser/SerialiserModule.cs | |||
@@ -46,7 +46,7 @@ namespace OpenSim.Region.CoreModules.World.Serialiser | |||
46 | private static readonly ILog m_log = | 46 | private static readonly ILog m_log = |
47 | LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 47 | LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
48 | 48 | ||
49 | private Commander m_commander = new Commander("export"); | 49 | // private Commander m_commander = new Commander("export"); |
50 | private List<Scene> m_regions = new List<Scene>(); | 50 | private List<Scene> m_regions = new List<Scene>(); |
51 | private string m_savedir = "exports"; | 51 | private string m_savedir = "exports"; |
52 | private List<IFileSerialiser> m_serialisers = new List<IFileSerialiser>(); | 52 | private List<IFileSerialiser> m_serialisers = new List<IFileSerialiser>(); |
@@ -77,14 +77,13 @@ namespace OpenSim.Region.CoreModules.World.Serialiser | |||
77 | m_serialisers.Add(new SerialiseObjects()); | 77 | m_serialisers.Add(new SerialiseObjects()); |
78 | } | 78 | } |
79 | 79 | ||
80 | LoadCommanderCommands(); | 80 | // LoadCommanderCommands(); |
81 | } | 81 | } |
82 | 82 | ||
83 | |||
84 | public void AddRegion(Scene scene) | 83 | public void AddRegion(Scene scene) |
85 | { | 84 | { |
86 | scene.RegisterModuleCommander(m_commander); | 85 | // scene.RegisterModuleCommander(m_commander); |
87 | scene.EventManager.OnPluginConsole += EventManager_OnPluginConsole; | 86 | // scene.EventManager.OnPluginConsole += EventManager_OnPluginConsole; |
88 | scene.RegisterModuleInterface<IRegionSerialiserModule>(this); | 87 | scene.RegisterModuleInterface<IRegionSerialiserModule>(this); |
89 | 88 | ||
90 | lock (m_regions) | 89 | lock (m_regions) |
@@ -211,18 +210,18 @@ namespace OpenSim.Region.CoreModules.World.Serialiser | |||
211 | 210 | ||
212 | #endregion | 211 | #endregion |
213 | 212 | ||
214 | private void EventManager_OnPluginConsole(string[] args) | 213 | // private void EventManager_OnPluginConsole(string[] args) |
215 | { | 214 | // { |
216 | if (args[0] == "export") | 215 | // if (args[0] == "export") |
217 | { | 216 | // { |
218 | string[] tmpArgs = new string[args.Length - 2]; | 217 | // string[] tmpArgs = new string[args.Length - 2]; |
219 | int i = 0; | 218 | // int i = 0; |
220 | for (i = 2; i < args.Length; i++) | 219 | // for (i = 2; i < args.Length; i++) |
221 | tmpArgs[i - 2] = args[i]; | 220 | // tmpArgs[i - 2] = args[i]; |
222 | 221 | // | |
223 | m_commander.ProcessConsoleCommand(args[1], tmpArgs); | 222 | // m_commander.ProcessConsoleCommand(args[1], tmpArgs); |
224 | } | 223 | // } |
225 | } | 224 | // } |
226 | 225 | ||
227 | private void InterfaceSaveRegion(Object[] args) | 226 | private void InterfaceSaveRegion(Object[] args) |
228 | { | 227 | { |
@@ -245,15 +244,15 @@ namespace OpenSim.Region.CoreModules.World.Serialiser | |||
245 | } | 244 | } |
246 | } | 245 | } |
247 | 246 | ||
248 | private void LoadCommanderCommands() | 247 | // private void LoadCommanderCommands() |
249 | { | 248 | // { |
250 | Command serialiseSceneCommand = new Command("save", CommandIntentions.COMMAND_NON_HAZARDOUS, InterfaceSaveRegion, "Saves the named region into the exports directory."); | 249 | // Command serialiseSceneCommand = new Command("save", CommandIntentions.COMMAND_NON_HAZARDOUS, InterfaceSaveRegion, "Saves the named region into the exports directory."); |
251 | serialiseSceneCommand.AddArgument("region-name", "The name of the region you wish to export", "String"); | 250 | // serialiseSceneCommand.AddArgument("region-name", "The name of the region you wish to export", "String"); |
252 | 251 | // | |
253 | Command serialiseAllScenesCommand = new Command("save-all",CommandIntentions.COMMAND_NON_HAZARDOUS, InterfaceSaveAllRegions, "Saves all regions into the exports directory."); | 252 | // Command serialiseAllScenesCommand = new Command("save-all",CommandIntentions.COMMAND_NON_HAZARDOUS, InterfaceSaveAllRegions, "Saves all regions into the exports directory."); |
254 | 253 | // | |
255 | m_commander.RegisterCommand("save", serialiseSceneCommand); | 254 | // m_commander.RegisterCommand("save", serialiseSceneCommand); |
256 | m_commander.RegisterCommand("save-all", serialiseAllScenesCommand); | 255 | // m_commander.RegisterCommand("save-all", serialiseAllScenesCommand); |
257 | } | 256 | // } |
258 | } | 257 | } |
259 | } | 258 | } |
diff --git a/OpenSim/Region/CoreModules/World/Sound/SoundModule.cs b/OpenSim/Region/CoreModules/World/Sound/SoundModule.cs index 8df44fe..09c0ebb 100644 --- a/OpenSim/Region/CoreModules/World/Sound/SoundModule.cs +++ b/OpenSim/Region/CoreModules/World/Sound/SoundModule.cs | |||
@@ -38,7 +38,7 @@ namespace OpenSim.Region.CoreModules.World.Sound | |||
38 | { | 38 | { |
39 | public class SoundModule : IRegionModule, ISoundModule | 39 | public class SoundModule : IRegionModule, ISoundModule |
40 | { | 40 | { |
41 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 41 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
42 | 42 | ||
43 | protected Scene m_scene; | 43 | protected Scene m_scene; |
44 | 44 | ||
diff --git a/OpenSim/Region/CoreModules/World/Warp3DMap/Perlin.cs b/OpenSim/Region/CoreModules/World/Warp3DMap/Perlin.cs index af59d7a..522a7eb 100644 --- a/OpenSim/Region/CoreModules/World/Warp3DMap/Perlin.cs +++ b/OpenSim/Region/CoreModules/World/Warp3DMap/Perlin.cs | |||
@@ -85,9 +85,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap | |||
85 | public static float noise1(float arg) | 85 | public static float noise1(float arg) |
86 | { | 86 | { |
87 | int bx0, bx1; | 87 | int bx0, bx1; |
88 | float rx0, rx1, sx, t, u, v, a; | 88 | float rx0, rx1, sx, t, u, v; |
89 | |||
90 | a = arg; | ||
91 | 89 | ||
92 | t = arg + N; | 90 | t = arg + N; |
93 | bx0 = ((int)t) & BM; | 91 | bx0 = ((int)t) & BM; |
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs index f9d28b9..e0f36a2 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs | |||
@@ -641,7 +641,17 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
641 | lock (m_openRequests) | 641 | lock (m_openRequests) |
642 | m_openRequests.Add(requestID, mrs); | 642 | m_openRequests.Add(requestID, mrs); |
643 | 643 | ||
644 | WebRequest mapitemsrequest = WebRequest.Create(httpserver); | 644 | WebRequest mapitemsrequest = null; |
645 | try | ||
646 | { | ||
647 | mapitemsrequest = WebRequest.Create(httpserver); | ||
648 | } | ||
649 | catch (Exception e) | ||
650 | { | ||
651 | m_log.DebugFormat("[WORLD MAP]: Access to {0} failed with {1}", httpserver, e); | ||
652 | return new OSDMap(); | ||
653 | } | ||
654 | |||
645 | mapitemsrequest.Method = "POST"; | 655 | mapitemsrequest.Method = "POST"; |
646 | mapitemsrequest.ContentType = "application/xml+llsd"; | 656 | mapitemsrequest.ContentType = "application/xml+llsd"; |
647 | OSDMap RAMap = new OSDMap(); | 657 | OSDMap RAMap = new OSDMap(); |