mirror of
https://github.com/opensim/opensim.git
synced 2026-08-09 18:55:58 +08:00
BulletSim: add osGetPhysicsEngineType() LSL function and update
the physics engines to return the name that is specified in the INI
file ("physics = XXX") as the type of engine.
This os function is a little different than the others in that it
does not throw an exception of one is not privilaged to use it.
It merely returns an empty string.
This commit is contained in:
@@ -59,7 +59,7 @@ public class BSPlugin : IPhysicsPlugin
|
||||
{
|
||||
if (_mScene == null)
|
||||
{
|
||||
_mScene = new BSScene(sceneIdentifier);
|
||||
_mScene = new BSScene(GetName(), sceneIdentifier);
|
||||
}
|
||||
return (_mScene);
|
||||
}
|
||||
|
||||
@@ -167,11 +167,16 @@ public sealed class BSScene : PhysicsScene, IPhysicsParameters
|
||||
public bool VehiclePhysicalLoggingEnabled { get; private set; }
|
||||
|
||||
#region Construction and Initialization
|
||||
public BSScene(string identifier)
|
||||
public BSScene(string engineType, string identifier)
|
||||
{
|
||||
m_initialized = false;
|
||||
// we are passed the name of the region we're working for.
|
||||
|
||||
// The name of the region we're working for is passed to us. Keep for identification.
|
||||
RegionName = identifier;
|
||||
|
||||
// Set identifying variables in the PhysicsScene interface.
|
||||
EngineType = engineType;
|
||||
Name = EngineType + "/" + RegionName;
|
||||
}
|
||||
|
||||
public override void Initialise(IMesher meshmerizer, IConfigSource config)
|
||||
|
||||
Reference in New Issue
Block a user