From 1dca94c72fabf06da4d85d6acad5894dabe79c5a Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Sat, 14 Jul 2012 20:10:38 +0100 Subject: [PATCH] don't subscribe collision events for nonphysical parts only because of collision sounds. Let them be passive --- OpenSim/Region/Framework/Scenes/CollisionSounds.cs | 1 + OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/OpenSim/Region/Framework/Scenes/CollisionSounds.cs b/OpenSim/Region/Framework/Scenes/CollisionSounds.cs index 075724eff8..21c9ab9344 100644 --- a/OpenSim/Region/Framework/Scenes/CollisionSounds.cs +++ b/OpenSim/Region/Framework/Scenes/CollisionSounds.cs @@ -31,6 +31,7 @@ using System.Reflection; using System.Collections.Generic; using OpenMetaverse; using OpenSim.Framework; +using OpenSim.Region.Physics.Manager; using log4net; namespace OpenSim.Region.Framework.Scenes diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs index 16a85883d1..735bd32671 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs @@ -4917,7 +4917,7 @@ namespace OpenSim.Region.Framework.Scenes pa.OnCollisionUpdate -= PhysicsCollision; - bool hassound = (CollisionSoundType >= 0 && !VolumeDetectActive); + bool hassound = (!VolumeDetectActive && CollisionSoundType >= 0 && ((Flags & PrimFlags.Physics) != 0)); scriptEvents CombinedEvents = AggregateScriptEvents;