aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Framework/AvatarAppearance.cs15
1 files changed, 9 insertions, 6 deletions
diff --git a/OpenSim/Framework/AvatarAppearance.cs b/OpenSim/Framework/AvatarAppearance.cs
index f442fc2..e1725a9 100644
--- a/OpenSim/Framework/AvatarAppearance.cs
+++ b/OpenSim/Framework/AvatarAppearance.cs
@@ -458,11 +458,11 @@ namespace OpenSim.Framework
458// m_log.WarnFormat("[AVATARAPPEARANCE] set wearable {0} --> {1}:{2}",wearableId,wearable.ItemID,wearable.AssetID); 458// m_log.WarnFormat("[AVATARAPPEARANCE] set wearable {0} --> {1}:{2}",wearableId,wearable.ItemID,wearable.AssetID);
459// DEBUG OFF 459// DEBUG OFF
460 m_wearables[wearableId].Clear(); 460 m_wearables[wearableId].Clear();
461 int count = wearable.Count; 461 int count = wearable.Count;
462 if (count > AvatarWearable.MAX_WEARABLES) 462 if (count > AvatarWearable.MAX_WEARABLES)
463 count = AvatarWearable.MAX_WEARABLES; 463 count = AvatarWearable.MAX_WEARABLES;
464 for (int i = 0; i < count; i++) 464 for (int i = 0; i < count; i++)
465 m_wearables[wearableId].Add(wearable[i].ItemID, wearable[i].AssetID); 465 m_wearables[wearableId].Add(wearable[i].ItemID, wearable[i].AssetID);
466 } 466 }
467 467
468// DEBUG ON 468// DEBUG ON
@@ -760,7 +760,10 @@ namespace OpenSim.Framework
760 if ((data != null) && (data["wearables"] != null) && (data["wearables"]).Type == OSDType.Array) 760 if ((data != null) && (data["wearables"] != null) && (data["wearables"]).Type == OSDType.Array)
761 { 761 {
762 OSDArray wears = (OSDArray)(data["wearables"]); 762 OSDArray wears = (OSDArray)(data["wearables"]);
763 for (int i = 0; i < wears.Count; i++) 763 int count = wears.Count;
764 if (count > AvatarWearable.MAX_WEARABLES)
765 count = AvatarWearable.MAX_WEARABLES;
766 for (int i = 0; i < count; i++)
764 m_wearables[i] = new AvatarWearable((OSDArray)wears[i]); 767 m_wearables[i] = new AvatarWearable((OSDArray)wears[i]);
765 } 768 }
766 else 769 else