aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes
diff options
context:
space:
mode:
authorMelanie2012-05-29 16:56:04 +0200
committerMelanie2012-05-29 16:56:04 +0200
commit10e9ad0086056f4afde081d629eca7cc6520a1ba (patch)
treec4fd0e0c1732efc3734110682ae5cf471ffa0ecb /OpenSim/Region/Framework/Scenes
parent fix avatars collisions on sim crossings and other few cases where freemove()... (diff)
downloadopensim-SC_OLD-10e9ad0086056f4afde081d629eca7cc6520a1ba.zip
opensim-SC_OLD-10e9ad0086056f4afde081d629eca7cc6520a1ba.tar.gz
opensim-SC_OLD-10e9ad0086056f4afde081d629eca7cc6520a1ba.tar.bz2
opensim-SC_OLD-10e9ad0086056f4afde081d629eca7cc6520a1ba.tar.xz
Fix collision filtering
Diffstat (limited to 'OpenSim/Region/Framework/Scenes')
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPart.cs20
1 files changed, 10 insertions, 10 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index 2852c4b..a57e9bc 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -2495,21 +2495,21 @@ namespace OpenSim.Region.Framework.Scenes
2495 { 2495 {
2496 } 2496 }
2497 2497
2498 private bool CollisionFilteredOut(SceneObjectPart dest, UUID objectID, string objectName) 2498 public bool CollisionFilteredOut(UUID objectID, string objectName)
2499 { 2499 {
2500 if(dest.CollisionFilter.Count == 0) 2500 if(CollisionFilter.Count == 0)
2501 return false; 2501 return false;
2502 2502
2503 if (dest.CollisionFilter.ContainsValue(objectID.ToString()) || 2503 if (CollisionFilter.ContainsValue(objectID.ToString()) ||
2504 dest.CollisionFilter.ContainsValue(objectID.ToString() + objectName) || 2504 CollisionFilter.ContainsValue(objectID.ToString() + objectName) ||
2505 dest.CollisionFilter.ContainsValue(UUID.Zero.ToString() + objectName)) 2505 CollisionFilter.ContainsValue(UUID.Zero.ToString() + objectName))
2506 { 2506 {
2507 if (dest.CollisionFilter.ContainsKey(1)) 2507 if (CollisionFilter.ContainsKey(1))
2508 return false; 2508 return false;
2509 return true; 2509 return true;
2510 } 2510 }
2511 2511
2512 if (dest.CollisionFilter.ContainsKey(1)) 2512 if (CollisionFilter.ContainsKey(1))
2513 return true; 2513 return true;
2514 2514
2515 return false; 2515 return false;
@@ -2572,7 +2572,7 @@ namespace OpenSim.Region.Framework.Scenes
2572 SceneObjectPart obj = ParentGroup.Scene.GetSceneObjectPart(localId); 2572 SceneObjectPart obj = ParentGroup.Scene.GetSceneObjectPart(localId);
2573 if (obj != null) 2573 if (obj != null)
2574 { 2574 {
2575 if (!dest.CollisionFilteredOut(this, obj.UUID, obj.Name)) 2575 if (!dest.CollisionFilteredOut(obj.UUID, obj.Name))
2576 colliding.Add(CreateDetObject(obj)); 2576 colliding.Add(CreateDetObject(obj));
2577 } 2577 }
2578 else 2578 else
@@ -2580,7 +2580,7 @@ namespace OpenSim.Region.Framework.Scenes
2580 ScenePresence av = ParentGroup.Scene.GetScenePresence(localId); 2580 ScenePresence av = ParentGroup.Scene.GetScenePresence(localId);
2581 if (av != null && (!av.IsChildAgent)) 2581 if (av != null && (!av.IsChildAgent))
2582 { 2582 {
2583 if (!dest.CollisionFilteredOut(this, av.UUID, av.Name)) 2583 if (!dest.CollisionFilteredOut(av.UUID, av.Name))
2584 colliding.Add(CreateDetObject(av)); 2584 colliding.Add(CreateDetObject(av));
2585 } 2585 }
2586 } 2586 }
@@ -2724,7 +2724,7 @@ namespace OpenSim.Region.Framework.Scenes
2724 2724
2725 SendCollisionEvent(scriptEvents.collision_start, startedColliders, ParentGroup.Scene.EventManager.TriggerScriptCollidingStart); 2725 SendCollisionEvent(scriptEvents.collision_start, startedColliders, ParentGroup.Scene.EventManager.TriggerScriptCollidingStart);
2726 if (!VolumeDetectActive) 2726 if (!VolumeDetectActive)
2727 SendCollisionEvent(scriptEvents.collision , m_lastColliders , ParentGroup.Scene.EventManager.TriggerScriptColliding); 2727 SendCollisionEvent(scriptEvents.collision , m_lastColliders , ParentGroup.Scene.EventManager.TriggerScriptColliding);
2728 SendCollisionEvent(scriptEvents.collision_end , endedColliders , ParentGroup.Scene.EventManager.TriggerScriptCollidingEnd); 2728 SendCollisionEvent(scriptEvents.collision_end , endedColliders , ParentGroup.Scene.EventManager.TriggerScriptCollidingEnd);
2729 2729
2730 if (startedColliders.Contains(0)) 2730 if (startedColliders.Contains(0))