diff options
author | diva | 2009-02-24 23:06:15 +0000 |
---|---|---|
committer | diva | 2009-02-24 23:06:15 +0000 |
commit | e84ac65b58b63ae4af18ab8ebd9a82664ff4ea21 (patch) | |
tree | 5915fc594231d83b3f0700b38e196d313c776723 /OpenSim/Region/Framework/Scenes/ScenePresence.cs | |
parent | More work on modulising the User Server. (diff) | |
download | opensim-SC-e84ac65b58b63ae4af18ab8ebd9a82664ff4ea21.zip opensim-SC-e84ac65b58b63ae4af18ab8ebd9a82664ff4ea21.tar.gz opensim-SC-e84ac65b58b63ae4af18ab8ebd9a82664ff4ea21.tar.bz2 opensim-SC-e84ac65b58b63ae4af18ab8ebd9a82664ff4ea21.tar.xz |
Close-to-final tweaking with appearance. This time sending *everything*. Addresses mantis #3223.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/ScenePresence.cs | 29 |
1 files changed, 8 insertions, 21 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 672567b..6fade39 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -2688,20 +2688,8 @@ namespace OpenSim.Region.Framework.Scenes | |||
2688 | 2688 | ||
2689 | cAgent.VisualParams = m_appearance.VisualParams; | 2689 | cAgent.VisualParams = m_appearance.VisualParams; |
2690 | 2690 | ||
2691 | // Textures is not really needed in the base case, I think. But it's handy for | 2691 | if (m_appearance.Texture != null) |
2692 | // the Hypergrid and other decentralized models, so that we know which | 2692 | cAgent.AgentTextures = m_appearance.Texture.ToBytes(); |
2693 | // textures to fecth from the user's asset server. | ||
2694 | i = 0; | ||
2695 | UUID[] textures = new UUID[m_appearance.Texture.FaceTextures.Length]; | ||
2696 | foreach (Primitive.TextureEntryFace face in m_appearance.Texture.FaceTextures) | ||
2697 | { | ||
2698 | if (face != null) | ||
2699 | textures[i] = face.TextureID; | ||
2700 | else | ||
2701 | textures[i] = UUID.Zero; | ||
2702 | ++i; | ||
2703 | } | ||
2704 | cAgent.AgentTextures = textures; | ||
2705 | } | 2693 | } |
2706 | catch (Exception e) | 2694 | catch (Exception e) |
2707 | { | 2695 | { |
@@ -2758,13 +2746,12 @@ namespace OpenSim.Region.Framework.Scenes | |||
2758 | } | 2746 | } |
2759 | m_appearance.Wearables = wears; | 2747 | m_appearance.Wearables = wears; |
2760 | 2748 | ||
2761 | // We're setting it here to default, but the viewer will soon send a SetAppearance that will | 2749 | byte[] te = null; |
2762 | // set things straight. We should probably parse these textures too, we have them... | 2750 | if (cAgent.AgentTextures != null) |
2763 | // In any case, the least we need to do is to check if this is HG and fetch the textures | 2751 | te = cAgent.AgentTextures; |
2764 | // so that they can then be distributed to the other clients that ask for them later. | 2752 | else |
2765 | Primitive.TextureEntry te = AvatarAppearance.GetDefaultTexture(); //new Primitive.TextureEntry(UUID.Random()); | 2753 | te = AvatarAppearance.GetDefaultTexture().ToBytes(); |
2766 | 2754 | m_appearance.SetAppearance(te, new List<byte>(cAgent.VisualParams)); | |
2767 | m_appearance.SetAppearance(te.ToBytes(), new List<byte>(cAgent.VisualParams)); | ||
2768 | } | 2755 | } |
2769 | catch (Exception e) | 2756 | catch (Exception e) |
2770 | { | 2757 | { |