aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes/Scene.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Scene.cs')
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.cs15
1 files changed, 9 insertions, 6 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs
index 40de870..b2cc750 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.cs
@@ -991,11 +991,10 @@ namespace OpenSim.Region.Environment.Scenes
991 { 991 {
992 ScenePresence avatar = null; 992 ScenePresence avatar = null;
993 993
994 byte[] visualParams; 994 AvatarAppearance appearance;
995 AvatarWearable[] wearables; 995 LoadAvatarAppearance(client, out appearance);
996 LoadAvatarAppearance(client, out visualParams, out wearables);
997 996
998 avatar = m_innerScene.CreateAndAddScenePresence(client, child, wearables, visualParams); 997 avatar = m_innerScene.CreateAndAddScenePresence(client, child, appearance);
999 998
1000 if (avatar.IsChildAgent) 999 if (avatar.IsChildAgent)
1001 { 1000 {
@@ -1005,12 +1004,16 @@ namespace OpenSim.Region.Environment.Scenes
1005 return avatar; 1004 return avatar;
1006 } 1005 }
1007 1006
1008 protected void LoadAvatarAppearance(IClientAPI client, out byte[] visualParams, out AvatarWearable[] wearables) 1007 protected void LoadAvatarAppearance(IClientAPI client, out AvatarAppearance appearance)
1009 { 1008 {
1010 if (m_AvatarFactory == null || 1009 if (m_AvatarFactory == null ||
1011 !m_AvatarFactory.TryGetInitialAvatarAppearance(client.AgentId, out wearables, out visualParams)) 1010 !m_AvatarFactory.TryGetAvatarAppearance(client.AgentId, out appearance))
1012 { 1011 {
1012 //not found Appearance
1013 byte[] visualParams;
1014 AvatarWearable[] wearables;
1013 AvatarFactoryModule.GetDefaultAvatarAppearance(out wearables, out visualParams); 1015 AvatarFactoryModule.GetDefaultAvatarAppearance(out wearables, out visualParams);
1016 appearance = new AvatarAppearance(client.AgentId, wearables, visualParams);
1014 } 1017 }
1015 } 1018 }
1016 1019