diff options
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin')
-rwxr-xr-x | OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs b/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs index e7cb3e0..534f929 100755 --- a/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs +++ b/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs | |||
@@ -343,6 +343,10 @@ public abstract class BSPhysObject : PhysicsActor | |||
343 | protected void RegisterPreStepAction(string op, uint id, BSScene.PreStepAction actn) | 343 | protected void RegisterPreStepAction(string op, uint id, BSScene.PreStepAction actn) |
344 | { | 344 | { |
345 | string identifier = op + "-" + id.ToString(); | 345 | string identifier = op + "-" + id.ToString(); |
346 | |||
347 | // Clean out any existing action | ||
348 | UnRegisterPreStepAction(op, id); | ||
349 | |||
346 | RegisteredActions[identifier] = actn; | 350 | RegisteredActions[identifier] = actn; |
347 | PhysicsScene.BeforeStep += actn; | 351 | PhysicsScene.BeforeStep += actn; |
348 | DetailLog("{0},BSPhysObject.RegisterPreStepAction,id={1}", LocalID, identifier); | 352 | DetailLog("{0},BSPhysObject.RegisterPreStepAction,id={1}", LocalID, identifier); |