aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes/Scene.cs
diff options
context:
space:
mode:
authorMW2007-08-23 17:21:08 +0000
committerMW2007-08-23 17:21:08 +0000
commit0d5311e49bf5700efcf779bfa4bc83a00585c424 (patch)
tree168ea226f01a7e486f4dd6f288ef00afdd67ff68 /OpenSim/Region/Environment/Scenes/Scene.cs
parentgrouping of functions to make the overall logic easier to grasp for people, (diff)
downloadopensim-SC_OLD-0d5311e49bf5700efcf779bfa4bc83a00585c424.zip
opensim-SC_OLD-0d5311e49bf5700efcf779bfa4bc83a00585c424.tar.gz
opensim-SC_OLD-0d5311e49bf5700efcf779bfa4bc83a00585c424.tar.bz2
opensim-SC_OLD-0d5311e49bf5700efcf779bfa4bc83a00585c424.tar.xz
Added RemovePrim method to the physics plugins interface.
Implemented that method in ODE plugin. Hooked it up so when deleting/taking prims into your inventory they will be removed from physics engine. Enabled the other physics hook ups in Scene.cs (and also added registering prims with physics plugin when they are rezzed from Inventory.) So now to get the avatar to prim collision testing working, just change to use the ODE plugin (in the OpenSim.ini file, physics = OpenDynamicsEngine). Remember though ODE only really works (without problems) when running with a single region.
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Scene.cs')
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.cs24
1 files changed, 12 insertions, 12 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs
index 87a42b1..282e548 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.cs
@@ -504,11 +504,11 @@ namespace OpenSim.Region.Environment.Scenes
504 { 504 {
505 AddEntityFromStorage(prim); 505 AddEntityFromStorage(prim);
506 SceneObjectPart rootPart = prim.GetChildPart(prim.UUID); 506 SceneObjectPart rootPart = prim.GetChildPart(prim.UUID);
507 // rootPart.PhysActor = phyScene.AddPrim( 507 rootPart.PhysActor = phyScene.AddPrim(
508 // new PhysicsVector(rootPart.AbsolutePosition.X, rootPart.AbsolutePosition.Y, rootPart.AbsolutePosition.Z), 508 new PhysicsVector(rootPart.AbsolutePosition.X, rootPart.AbsolutePosition.Y, rootPart.AbsolutePosition.Z),
509 // new PhysicsVector(rootPart.Scale.X, rootPart.Scale.Y, rootPart.Scale.Z), 509 new PhysicsVector(rootPart.Scale.X, rootPart.Scale.Y, rootPart.Scale.Z),
510 // new Axiom.Math.Quaternion(rootPart.RotationOffset.W, rootPart.RotationOffset.X, 510 new Axiom.Math.Quaternion(rootPart.RotationOffset.W, rootPart.RotationOffset.X,
511 // rootPart.RotationOffset.Y, rootPart.RotationOffset.Z)); 511 rootPart.RotationOffset.Y, rootPart.RotationOffset.Z));
512 } 512 }
513 MainLog.Instance.Verbose("Loaded " + PrimsFromDB.Count.ToString() + " SceneObject(s)"); 513 MainLog.Instance.Verbose("Loaded " + PrimsFromDB.Count.ToString() + " SceneObject(s)");
514 } 514 }
@@ -547,8 +547,8 @@ namespace OpenSim.Region.Environment.Scenes
547 SceneObjectGroup sceneOb = new SceneObjectGroup(this, this.m_regionHandle, ownerID, PrimIDAllocate(), pos, shape); 547 SceneObjectGroup sceneOb = new SceneObjectGroup(this, this.m_regionHandle, ownerID, PrimIDAllocate(), pos, shape);
548 AddEntity(sceneOb); 548 AddEntity(sceneOb);
549 SceneObjectPart rootPart = sceneOb.GetChildPart(sceneOb.UUID); 549 SceneObjectPart rootPart = sceneOb.GetChildPart(sceneOb.UUID);
550 //rootPart.PhysActor =phyScene.AddPrim(new PhysicsVector(pos.X, pos.Y, pos.Z), new PhysicsVector(shape.Scale.X, shape.Scale.Y, shape.Scale.Z), 550 rootPart.PhysActor =phyScene.AddPrim(new PhysicsVector(pos.X, pos.Y, pos.Z), new PhysicsVector(shape.Scale.X, shape.Scale.Y, shape.Scale.Z),
551 // new Axiom.Math.Quaternion()); 551 new Axiom.Math.Quaternion());
552 } 552 }
553 553
554 public void RemovePrim(uint localID, LLUUID avatar_deleter) 554 public void RemovePrim(uint localID, LLUUID avatar_deleter)
@@ -626,11 +626,11 @@ namespace OpenSim.Region.Environment.Scenes
626 AddEntity(obj); 626 AddEntity(obj);
627 627
628 SceneObjectPart rootPart = obj.GetChildPart(obj.UUID); 628 SceneObjectPart rootPart = obj.GetChildPart(obj.UUID);
629 //rootPart.PhysActor = phyScene.AddPrim( 629 rootPart.PhysActor = phyScene.AddPrim(
630 // new PhysicsVector(rootPart.AbsolutePosition.X, rootPart.AbsolutePosition.Y, rootPart.AbsolutePosition.Z), 630 new PhysicsVector(rootPart.AbsolutePosition.X, rootPart.AbsolutePosition.Y, rootPart.AbsolutePosition.Z),
631 // new PhysicsVector(rootPart.Scale.X, rootPart.Scale.Y, rootPart.Scale.Z), 631 new PhysicsVector(rootPart.Scale.X, rootPart.Scale.Y, rootPart.Scale.Z),
632 // new Axiom.Math.Quaternion(rootPart.RotationOffset.W, rootPart.RotationOffset.X, 632 new Axiom.Math.Quaternion(rootPart.RotationOffset.W, rootPart.RotationOffset.X,
633 // rootPart.RotationOffset.Y, rootPart.RotationOffset.Z)); 633 rootPart.RotationOffset.Y, rootPart.RotationOffset.Z));
634 primCount++; 634 primCount++;
635 } 635 }
636 } 636 }