From 70be30fbaa6f41ae3849eb33fb23aebdeb02e3b8 Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Sun, 21 Sep 2008 00:05:33 +0000 Subject: Completely revert the notecard uploading changes I made, since they appear to break script saves in prims for some. --- OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'OpenSim/Region/Environment/Scenes') diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs index f5ac035..f575ecd 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs @@ -254,10 +254,10 @@ namespace OpenSim.Region.Environment.Scenes return; } - AssetBase asset = CreateAsset(item.Name, item.Description, (sbyte)item.Type, data); + AssetBase asset = CreateAsset(item.Name, item.Description, (sbyte)AssetType.LSLText, data); AssetCache.AddAsset(asset); - if (isScriptRunning && item.Type == 10) + if (isScriptRunning) { part.RemoveScriptInstance(item.ItemID); } @@ -267,7 +267,7 @@ namespace OpenSim.Region.Environment.Scenes part.GetProperties(remoteClient); // Trigger rerunning of script (use TriggerRezScript event, see RezScript) - if (isScriptRunning && item.Type == 10) + if (isScriptRunning) { part.CreateScriptInstance(item.ItemID, 0, false); } @@ -1235,6 +1235,7 @@ namespace OpenSim.Region.Environment.Scenes else // Updating existing item with new perms etc { TaskInventoryItem prevItem = part.GetInventoryItem(itemID); +System.Console.WriteLine("Item asset {0}, request asset {1}", prevItem.AssetID.ToString(), itemInfo.AssetID.ToString()); itemInfo.AssetID = prevItem.AssetID; if (part.UpdateInventoryItem(itemInfo)) part.GetProperties(remoteClient); -- cgit v1.1