aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework
diff options
context:
space:
mode:
authorMelanie2010-06-24 03:30:11 +0100
committerMelanie2010-06-24 03:30:11 +0100
commite93853623bd2744f89c6c508bef2a3eff3a6aaf9 (patch)
tree96cec1ef37a393f9e16cd604e61566936fba4d83 /OpenSim/Region/Framework
parentMerge branch 'master' into careminster-presence-refactor (diff)
parentMove loading of parcels to before script start. Scripts using parcel functions (diff)
downloadopensim-SC_OLD-e93853623bd2744f89c6c508bef2a3eff3a6aaf9.zip
opensim-SC_OLD-e93853623bd2744f89c6c508bef2a3eff3a6aaf9.tar.gz
opensim-SC_OLD-e93853623bd2744f89c6c508bef2a3eff3a6aaf9.tar.bz2
opensim-SC_OLD-e93853623bd2744f89c6c508bef2a3eff3a6aaf9.tar.xz
Merge branch 'master' into careminster-presence-refactor
Diffstat (limited to 'OpenSim/Region/Framework')
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs21
1 files changed, 20 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
index c3cdca8..5be71df 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
@@ -31,6 +31,7 @@ using System.IO;
31using System.Collections.Generic; 31using System.Collections.Generic;
32using System.Collections; 32using System.Collections;
33using System.Reflection; 33using System.Reflection;
34using System.Threading;
34using OpenMetaverse; 35using OpenMetaverse;
35using log4net; 36using log4net;
36using OpenSim.Framework; 37using OpenSim.Framework;
@@ -208,6 +209,7 @@ namespace OpenSim.Region.Framework.Scenes
208 if ((int)InventoryType.LSL == item.InvType) 209 if ((int)InventoryType.LSL == item.InvType)
209 { 210 {
210 CreateScriptInstance(item, startParam, postOnRez, engine, stateSource); 211 CreateScriptInstance(item, startParam, postOnRez, engine, stateSource);
212 Thread.Sleep(10); // workaround for Mono cpu utilization > 100% bug
211 } 213 }
212 } 214 }
213 } 215 }
@@ -268,7 +270,7 @@ namespace OpenSim.Region.Framework.Scenes
268 // m_log.InfoFormat( 270 // m_log.InfoFormat(
269 // "[PRIM INVENTORY]: " + 271 // "[PRIM INVENTORY]: " +
270 // "Starting script {0}, {1} in prim {2}, {3}", 272 // "Starting script {0}, {1} in prim {2}, {3}",
271 // item.Name, item.ItemID, Name, UUID); 273 // item.Name, item.ItemID, m_part.Name, m_part.UUID);
272 274
273 if (!m_part.ParentGroup.Scene.Permissions.CanRunScript(item.ItemID, m_part.UUID, item.OwnerID)) 275 if (!m_part.ParentGroup.Scene.Permissions.CanRunScript(item.ItemID, m_part.UUID, item.OwnerID))
274 { 276 {
@@ -308,6 +310,7 @@ namespace OpenSim.Region.Framework.Scenes
308 } 310 }
309 else 311 else
310 { 312 {
313<<<<<<< HEAD:OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
311 if (m_part.ParentGroup.m_savedScriptState != null) 314 if (m_part.ParentGroup.m_savedScriptState != null)
312 RestoreSavedScriptState(item.OldItemID, item.ItemID); 315 RestoreSavedScriptState(item.OldItemID, item.ItemID);
313 316
@@ -324,6 +327,22 @@ namespace OpenSim.Region.Framework.Scenes
324 StoreScriptErrors(item.ItemID, null); 327 StoreScriptErrors(item.ItemID, null);
325 m_part.ParentGroup.AddActiveScriptCount(1); 328 m_part.ParentGroup.AddActiveScriptCount(1);
326 m_part.ScheduleFullUpdate(); 329 m_part.ScheduleFullUpdate();
330=======
331 lock (m_items)
332 {
333 if (m_part.ParentGroup.m_savedScriptState != null)
334 RestoreSavedScriptState(item.OldItemID, item.ItemID);
335
336 m_items[item.ItemID].PermsMask = 0;
337 m_items[item.ItemID].PermsGranter = UUID.Zero;
338
339 string script = Utils.BytesToString(asset.Data);
340 m_part.ParentGroup.Scene.EventManager.TriggerRezScript(
341 m_part.LocalId, item.ItemID, script, startParam, postOnRez, engine, stateSource);
342 m_part.ParentGroup.AddActiveScriptCount(1);
343 m_part.ScheduleFullUpdate();
344 }
345>>>>>>> master:OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
327 } 346 }
328 } 347 }
329 } 348 }