aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/ApplicationPlugins
diff options
context:
space:
mode:
authoropensim mirror account2010-10-29 13:20:04 -0700
committeropensim mirror account2010-10-29 13:20:04 -0700
commit8d8a795b28c3955df309a4f8cfd3b092489cb15f (patch)
tree672d0d8327d521dfefb44dc5d7d1d49ed8642ee0 /OpenSim/ApplicationPlugins
parentMerge branch 'master' of /var/git/opensim/ (diff)
parentMerge branch 'dev-appearance' (diff)
downloadopensim-SC-8d8a795b28c3955df309a4f8cfd3b092489cb15f.zip
opensim-SC-8d8a795b28c3955df309a4f8cfd3b092489cb15f.tar.gz
opensim-SC-8d8a795b28c3955df309a4f8cfd3b092489cb15f.tar.bz2
opensim-SC-8d8a795b28c3955df309a4f8cfd3b092489cb15f.tar.xz
Merge branch 'master' of /var/git/opensim/
Diffstat (limited to 'OpenSim/ApplicationPlugins')
-rw-r--r--OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs28
1 files changed, 10 insertions, 18 deletions
diff --git a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs
index aeed467..0589748 100644
--- a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs
+++ b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs
@@ -1472,12 +1472,9 @@ namespace OpenSim.ApplicationPlugins.RemoteController
1472 { 1472 {
1473 m_log.DebugFormat("[RADMIN] Initializing inventory for {0} from {1}", destination, source); 1473 m_log.DebugFormat("[RADMIN] Initializing inventory for {0} from {1}", destination, source);
1474 Scene scene = m_application.SceneManager.CurrentOrFirstScene; 1474 Scene scene = m_application.SceneManager.CurrentOrFirstScene;
1475 AvatarAppearance avatarAppearance = null;
1476 AvatarData avatar = scene.AvatarService.GetAvatar(source);
1477 if (avatar != null)
1478 avatarAppearance = avatar.ToAvatarAppearance(source);
1479 1475
1480 // If the model has no associated appearance we're done. 1476 // If the model has no associated appearance we're done.
1477 AvatarAppearance avatarAppearance = scene.AvatarService.GetAppearance(source);
1481 if (avatarAppearance == null) 1478 if (avatarAppearance == null)
1482 return; 1479 return;
1483 1480
@@ -1491,8 +1488,7 @@ namespace OpenSim.ApplicationPlugins.RemoteController
1491 { 1488 {
1492 CopyWearablesAndAttachments(destination, source, avatarAppearance); 1489 CopyWearablesAndAttachments(destination, source, avatarAppearance);
1493 1490
1494 AvatarData avatarData = new AvatarData(avatarAppearance); 1491 scene.AvatarService.SetAppearance(destination, avatarAppearance);
1495 scene.AvatarService.SetAvatar(destination, avatarData);
1496 } 1492 }
1497 catch (Exception e) 1493 catch (Exception e)
1498 { 1494 {
@@ -1523,8 +1519,7 @@ namespace OpenSim.ApplicationPlugins.RemoteController
1523 } 1519 }
1524 } 1520 }
1525 1521
1526 AvatarData avatarData = new AvatarData(avatarAppearance); 1522 scene.AvatarService.SetAppearance(destination, avatarAppearance);
1527 scene.AvatarService.SetAvatar(destination, avatarData);
1528 } 1523 }
1529 catch (Exception e) 1524 catch (Exception e)
1530 { 1525 {
@@ -1619,12 +1614,12 @@ namespace OpenSim.ApplicationPlugins.RemoteController
1619 } 1614 }
1620 1615
1621 // Attachments 1616 // Attachments
1622 Dictionary<int, UUID[]> attachments = avatarAppearance.GetAttachmentDictionary(); 1617 Dictionary<int, AvatarAttachment> attachments = avatarAppearance.Attachments;
1623 1618
1624 foreach (KeyValuePair<int, UUID[]> attachment in attachments) 1619 foreach (KeyValuePair<int, AvatarAttachment> attachment in attachments)
1625 { 1620 {
1626 int attachpoint = attachment.Key; 1621 int attachpoint = attachment.Value.AttachPoint;
1627 UUID itemID = attachment.Value[0]; 1622 UUID itemID = attachment.Value.ItemID;
1628 1623
1629 if (itemID != UUID.Zero) 1624 if (itemID != UUID.Zero)
1630 { 1625 {
@@ -1908,10 +1903,8 @@ namespace OpenSim.ApplicationPlugins.RemoteController
1908 if (include) 1903 if (include)
1909 { 1904 {
1910 // Setup for appearance processing 1905 // Setup for appearance processing
1911 AvatarData avatarData = scene.AvatarService.GetAvatar(ID); 1906 avatarAppearance = scene.AvatarService.GetAppearance(ID);
1912 if (avatarData != null) 1907 if (avatarAppearance == null)
1913 avatarAppearance = avatarData.ToAvatarAppearance(ID);
1914 else
1915 avatarAppearance = new AvatarAppearance(); 1908 avatarAppearance = new AvatarAppearance();
1916 1909
1917 AvatarWearable[] wearables = avatarAppearance.Wearables; 1910 AvatarWearable[] wearables = avatarAppearance.Wearables;
@@ -2076,8 +2069,7 @@ namespace OpenSim.ApplicationPlugins.RemoteController
2076 m_log.DebugFormat("[RADMIN] Outfit {0} load completed", outfitName); 2069 m_log.DebugFormat("[RADMIN] Outfit {0} load completed", outfitName);
2077 } // foreach outfit 2070 } // foreach outfit
2078 m_log.DebugFormat("[RADMIN] Inventory update complete for {0}", name); 2071 m_log.DebugFormat("[RADMIN] Inventory update complete for {0}", name);
2079 AvatarData avatarData2 = new AvatarData(avatarAppearance); 2072 scene.AvatarService.SetAppearance(ID, avatarAppearance);
2080 scene.AvatarService.SetAvatar(ID, avatarData2);
2081 } 2073 }
2082 catch (Exception e) 2074 catch (Exception e)
2083 { 2075 {