diff options
author | Justin Clark-Casey (justincc) | 2010-08-23 23:16:48 +0100 |
---|---|---|
committer | Diva Canto | 2010-08-24 17:22:08 -0700 |
commit | 269c9a11b7253413c0dc139b6ca0b76bd1c65b12 (patch) | |
tree | 28ef052c92d9b5b9981ffde09e302b51f81d2d84 /OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |
parent | Remove various warnings and improve logging messages. No functional changes. (diff) | |
download | opensim-SC_OLD-269c9a11b7253413c0dc139b6ca0b76bd1c65b12.zip opensim-SC_OLD-269c9a11b7253413c0dc139b6ca0b76bd1c65b12.tar.gz opensim-SC_OLD-269c9a11b7253413c0dc139b6ca0b76bd1c65b12.tar.bz2 opensim-SC_OLD-269c9a11b7253413c0dc139b6ca0b76bd1c65b12.tar.xz |
Fix bug in llGiveInventory() where items were disappearing on relog
This was a regression - the code to look up the correct type folder was no longer being called if items were added without a parent folder set
This may have been broken since commit bd49985a on 2010-05-02
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index f767c64..9451005 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -3837,18 +3837,16 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3837 | if (World.GetScenePresence(destId) != null) | 3837 | if (World.GetScenePresence(destId) != null) |
3838 | { | 3838 | { |
3839 | // destination is an avatar | 3839 | // destination is an avatar |
3840 | InventoryItemBase agentItem = | 3840 | InventoryItemBase agentItem = World.MoveTaskInventoryItem(destId, UUID.Zero, m_host, objId); |
3841 | World.MoveTaskInventoryItem(destId, UUID.Zero, m_host, objId); | ||
3842 | 3841 | ||
3843 | if (agentItem == null) | 3842 | if (agentItem == null) |
3844 | return; | 3843 | return; |
3845 | 3844 | ||
3846 | byte[] bucket = new byte[17]; | 3845 | byte[] bucket = new byte[17]; |
3847 | bucket[0] = (byte)assetType; | 3846 | bucket[0] = (byte)assetType; |
3848 | byte[] objBytes = objId.GetBytes(); | 3847 | byte[] objBytes = agentItem.ID.GetBytes(); |
3849 | Array.Copy(objBytes, 0, bucket, 1, 16); | 3848 | Array.Copy(objBytes, 0, bucket, 1, 16); |
3850 | 3849 | ||
3851 | Console.WriteLine("Giving inventory"); | ||
3852 | GridInstantMessage msg = new GridInstantMessage(World, | 3850 | GridInstantMessage msg = new GridInstantMessage(World, |
3853 | m_host.UUID, m_host.Name+", an object owned by "+ | 3851 | m_host.UUID, m_host.Name+", an object owned by "+ |
3854 | resolveName(m_host.OwnerID)+",", destId, | 3852 | resolveName(m_host.OwnerID)+",", destId, |