From f99b4cbe3b53abcbfe5e751474085f7653997cc4 Mon Sep 17 00:00:00 2001 From: Sean Dague Date: Fri, 16 May 2008 19:24:28 +0000 Subject: prime the wearables structure, which should fix the exception FluxOne found. --- OpenSim/Framework/AvatarAppearance.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/OpenSim/Framework/AvatarAppearance.cs b/OpenSim/Framework/AvatarAppearance.cs index d4bfb2c..53c0d92 100644 --- a/OpenSim/Framework/AvatarAppearance.cs +++ b/OpenSim/Framework/AvatarAppearance.cs @@ -371,6 +371,14 @@ namespace OpenSim.Framework VisualParams = (byte[])h["visual_params"]; Texture = new LLObject.TextureEntry((byte[])h["texture"], 0, ((byte[])h["texture"]).Length); AvatarHeight = (float)Convert.ToDouble((string)h["avatar_height"]); + + m_wearables = new AvatarWearable[MAX_WEARABLES]; + for (int i = 0; i < MAX_WEARABLES; i++) + { + // this makes them all null + m_wearables[i] = new AvatarWearable(); + } + BodyItem = new LLUUID((string)h["body_item"]); BodyAsset = new LLUUID((string)h["body_asset"]); SkinItem = new LLUUID((string)h["skin_item"]); -- cgit v1.1