aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-10-25 22:19:17 +0100
committerJustin Clark-Casey (justincc)2011-10-25 22:19:17 +0100
commit5d37f0471ea504b1426536987d05c7d64dd199ae (patch)
tree66c539fdad4f63939ff3e976240e5a57d2952759 /OpenSim/Region/Physics/OdePlugin/ODECharacter.cs
parentFix bug where collision event listeners were not removed once the listener ha... (diff)
downloadopensim-SC_OLD-5d37f0471ea504b1426536987d05c7d64dd199ae.zip
opensim-SC_OLD-5d37f0471ea504b1426536987d05c7d64dd199ae.tar.gz
opensim-SC_OLD-5d37f0471ea504b1426536987d05c7d64dd199ae.tar.bz2
opensim-SC_OLD-5d37f0471ea504b1426536987d05c7d64dd199ae.tar.xz
For ScenePresence collision events, instead of creating a new CollisionEventsThisFrame every time we need to send some new ones, reuse the existing one instead.
This assumes that the listener is using the data synchronously, which is currently the case.
Diffstat (limited to 'OpenSim/Region/Physics/OdePlugin/ODECharacter.cs')
-rw-r--r--OpenSim/Region/Physics/OdePlugin/ODECharacter.cs8
1 files changed, 3 insertions, 5 deletions
diff --git a/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs b/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs
index e9bab66..55e14bc 100644
--- a/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs
+++ b/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs
@@ -1235,11 +1235,9 @@ namespace OpenSim.Region.Physics.OdePlugin
1235 { 1235 {
1236 if (m_eventsubscription > m_requestedUpdateFrequency) 1236 if (m_eventsubscription > m_requestedUpdateFrequency)
1237 { 1237 {
1238 if (CollisionEventsThisFrame != null) 1238 base.SendCollisionUpdate(CollisionEventsThisFrame);
1239 { 1239
1240 base.SendCollisionUpdate(CollisionEventsThisFrame); 1240 CollisionEventsThisFrame.Clear();
1241 }
1242 CollisionEventsThisFrame = new CollisionEventUpdate();
1243 m_eventsubscription = 0; 1241 m_eventsubscription = 0;
1244 } 1242 }
1245 } 1243 }