From 63d2885008b0e5b01dd362c7e932e3c1818efa0a Mon Sep 17 00:00:00 2001 From: idb Date: Sun, 18 Jan 2009 14:46:43 +0000 Subject: Moved applying an impulse to a newly rezzed object to minimise the delay getting the object moving. --- OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/Environment/Scenes') diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs index 750b5b9..4db735a 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs @@ -2472,7 +2472,12 @@ namespace OpenSim.Region.Environment.Scenes } group.UpdateGroupRotation(rot); //group.ApplyPhysics(m_physicalPrim); - group.Velocity = vel; + if (group.RootPart.PhysActor != null && group.RootPart.PhysActor.IsPhysical && vel != Vector3.Zero) + { + group.RootPart.ApplyImpulse(vel, false); + group.Velocity = vel; + rootPart.ScheduleFullUpdate(); + } group.CreateScriptInstances(param, true, DefaultScriptEngine, 2); rootPart.ScheduleFullUpdate(); -- cgit v1.1