aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-07-12 02:33:09 +0100
committerJustin Clark-Casey (justincc)2011-07-12 02:33:09 +0100
commitdf0e5cc9fe9b0851ae5442bdeeb49ab7778d5fe1 (patch)
tree1435bbc275609382086cd57c905b85f4bac67cb2 /OpenSim/Region/Framework/Scenes
parentFix permissions problem where newly uploaded meshes rezzed from inventory cou... (diff)
downloadopensim-SC_OLD-df0e5cc9fe9b0851ae5442bdeeb49ab7778d5fe1.zip
opensim-SC_OLD-df0e5cc9fe9b0851ae5442bdeeb49ab7778d5fe1.tar.gz
opensim-SC_OLD-df0e5cc9fe9b0851ae5442bdeeb49ab7778d5fe1.tar.bz2
opensim-SC_OLD-df0e5cc9fe9b0851ae5442bdeeb49ab7778d5fe1.tar.xz
When a mesh object is added to a scene, delay adding the physics actor until the sculpt data has been added to the shape (possibly via an async asset service request)
This prevents spurious 'no asset data' for meshes added on startup.
Diffstat (limited to 'OpenSim/Region/Framework/Scenes')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs5
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs2
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPart.cs7
3 files changed, 10 insertions, 4 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 8195a0d..0104a96 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -1751,8 +1751,9 @@ namespace OpenSim.Region.Framework.Scenes
1751 SceneObjectPart rootPart = group.GetChildPart(group.UUID); 1751 SceneObjectPart rootPart = group.GetChildPart(group.UUID);
1752 rootPart.Flags &= ~PrimFlags.Scripted; 1752 rootPart.Flags &= ~PrimFlags.Scripted;
1753 rootPart.TrimPermissions(); 1753 rootPart.TrimPermissions();
1754 group.CheckSculptAndLoad(); 1754
1755 //rootPart.DoPhysicsPropertyUpdate(UsePhysics, true); 1755 // Don't do this here - it will get done later on when sculpt data is loaded.
1756// group.CheckSculptAndLoad();
1756 } 1757 }
1757 1758
1758 m_log.Info("[SCENE]: Loaded " + PrimsFromDB.Count.ToString() + " SceneObject(s)"); 1759 m_log.Info("[SCENE]: Loaded " + PrimsFromDB.Count.ToString() + " SceneObject(s)");
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
index fa23fcd..905acd6 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
@@ -584,7 +584,7 @@ namespace OpenSim.Region.Framework.Scenes
584 part.ParentID = m_rootPart.LocalId; 584 part.ParentID = m_rootPart.LocalId;
585 //m_log.DebugFormat("[SCENE]: Given local id {0} to part {1}, linknum {2}, parent {3} {4}", part.LocalId, part.UUID, part.LinkNum, part.ParentID, part.ParentUUID); 585 //m_log.DebugFormat("[SCENE]: Given local id {0} to part {1}, linknum {2}, parent {3} {4}", part.LocalId, part.UUID, part.LinkNum, part.ParentID, part.ParentUUID);
586 } 586 }
587 587
588 ApplyPhysics(m_scene.m_physicalPrim); 588 ApplyPhysics(m_scene.m_physicalPrim);
589 589
590 // Don't trigger the update here - otherwise some client issues occur when multiple updates are scheduled 590 // Don't trigger the update here - otherwise some client issues occur when multiple updates are scheduled
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index 2026c53..e9571aa 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -1896,7 +1896,12 @@ namespace OpenSim.Region.Framework.Scenes
1896 } 1896 }
1897 } 1897 }
1898 1898
1899 m_parentGroup.Scene.PhysicsScene.AddPhysicsActorTaint(PhysActor); 1899 // If this part is a sculpt then delay the physics update until we've asynchronously loaded the
1900 // mesh data.
1901 if (((OpenMetaverse.SculptType)Shape.SculptType) == SculptType.Mesh)
1902 CheckSculptAndLoad();
1903 else
1904 m_parentGroup.Scene.PhysicsScene.AddPhysicsActorTaint(PhysActor);
1900 } 1905 }
1901 } 1906 }
1902 } 1907 }