From f4fe8763ad4f4cb85ff38eb65f1138baee74ece1 Mon Sep 17 00:00:00 2001 From: SignpostMarv Date: Fri, 5 Oct 2012 14:37:55 +0100 Subject: [PATCH] Changing the logic order in the TaskInventory iterator of ScenObjectPart.SendSound, since we can currently have non-unique object inventory names so we should check the asset type first. --- OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs index a539effa12..681feea4be 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs @@ -2701,7 +2701,7 @@ namespace OpenSim.Region.Framework.Scenes { foreach (KeyValuePair item in TaskInventory) { - if (item.Value.Name == sound && item.Value.Type == (int)AssetType.Sound) + if (item.Value.Type == (int)AssetType.Sound && item.Value.Name == sound) { soundID = item.Value.ItemID; break;