* part one of adding physics combining

remotes/origin/0.6.7-post-fixes
Teravus Ovares (Dan Olivares) 2009-08-15 13:10:10 -04:00
parent eedb155502
commit 8000812700
3 changed files with 20 additions and 0 deletions

View File

@ -10,6 +10,7 @@
<Extension path = "/OpenSim/RegionModules"> <Extension path = "/OpenSim/RegionModules">
<RegionModule id="CapabilitiesModule" type="OpenSim.Region.CoreModules.Agent.Capabilities.CapabilitiesModule" /> <RegionModule id="CapabilitiesModule" type="OpenSim.Region.CoreModules.Agent.Capabilities.CapabilitiesModule" />
<RegionModule id="TerrainModule" type="OpenSim.Region.CoreModules.World.Terrain.TerrainModule" /> <RegionModule id="TerrainModule" type="OpenSim.Region.CoreModules.World.Terrain.TerrainModule" />
<RegionModule id="PhysicsCombiner" type="OpenSim.Region.CoreModules.World.Land.PhysicsCombiner" />
<RegionModule id="WorldMapModule" type="OpenSim.Region.CoreModules.World.WorldMap.WorldMapModule" /> <RegionModule id="WorldMapModule" type="OpenSim.Region.CoreModules.World.WorldMap.WorldMapModule" />
<RegionModule id="HGWorldMapModule" type="OpenSim.Region.CoreModules.Hypergrid.HGWorldMapModule" /> <RegionModule id="HGWorldMapModule" type="OpenSim.Region.CoreModules.Hypergrid.HGWorldMapModule" />
<RegionModule id="UrlModule" type="OpenSim.Region.CoreModules.Scripting.LSLHttp.UrlModule" /> <RegionModule id="UrlModule" type="OpenSim.Region.CoreModules.Scripting.LSLHttp.UrlModule" />

View File

@ -162,6 +162,16 @@ namespace OpenSim.Region.Physics.Manager
return false; return false;
} }
public virtual bool SupportsCombining()
{
return false;
}
public virtual void Combine(PhysicsScene pScene, Vector3 offset)
{
return;
}
/// <summary> /// <summary>
/// Queue a raycast against the physics scene. /// Queue a raycast against the physics scene.
/// The provided callback method will be called when the raycast is complete /// The provided callback method will be called when the raycast is complete

View File

@ -313,6 +313,9 @@ namespace OpenSim.Region.Physics.OdePlugin
private volatile int m_global_contactcount = 0; private volatile int m_global_contactcount = 0;
private Vector3 m_worldOffset = Vector3.Zero;
private Vector2 m_worldExtents = new Vector2((int)Constants.RegionSize, (int)Constants.RegionSize);
private ODERayCastRequestManager m_rayCastManager; private ODERayCastRequestManager m_rayCastManager;
/// <summary> /// <summary>
@ -1653,6 +1656,7 @@ namespace OpenSim.Region.Physics.OdePlugin
private PhysicsActor AddPrim(String name, PhysicsVector position, PhysicsVector size, Quaternion rotation, private PhysicsActor AddPrim(String name, PhysicsVector position, PhysicsVector size, Quaternion rotation,
IMesh mesh, PrimitiveBaseShape pbs, bool isphysical) IMesh mesh, PrimitiveBaseShape pbs, bool isphysical)
{ {
PhysicsVector pos = new PhysicsVector(position.X, position.Y, position.Z); PhysicsVector pos = new PhysicsVector(position.X, position.Y, position.Z);
//pos.X = position.X; //pos.X = position.X;
//pos.Y = position.Y; //pos.Y = position.Y;
@ -2555,6 +2559,9 @@ namespace OpenSim.Region.Physics.OdePlugin
if (framecount >= int.MaxValue) if (framecount >= int.MaxValue)
framecount = 0; framecount = 0;
if (m_worldOffset != Vector3.Zero)
return 0;
framecount++; framecount++;
float fps = 0; float fps = 0;
@ -3377,6 +3384,8 @@ namespace OpenSim.Region.Physics.OdePlugin
return waterlevel; return waterlevel;
} }
public override void SetWaterLevel(float baseheight) public override void SetWaterLevel(float baseheight)
{ {
waterlevel = baseheight; waterlevel = baseheight;