Add glue for llSetVehicleFlags(), llRemoveVehicleFlags(). ChODE: Add associated methods.

avinationmerge
Kitto Flora 2010-01-21 19:31:02 -05:00
parent 66692f90e3
commit 1abb70cc73
15 changed files with 174 additions and 4 deletions

View File

@ -2964,6 +2964,22 @@ namespace OpenSim.Region.Framework.Scenes
} }
} }
public void SetVehicleFlags(int flags)
{
if (PhysActor != null)
{
PhysActor.VehicleFlagsSet(flags);
}
}
public void RemoveVehicleFlags(int flags)
{
if (PhysActor != null)
{
PhysActor.VehicleFlagsRemove(flags);
}
}
public void SetGroup(UUID groupID, IClientAPI client) public void SetGroup(UUID groupID, IClientAPI client)
{ {
_groupID = groupID; _groupID = groupID;

View File

@ -185,6 +185,16 @@ namespace OpenSim.Region.Physics.BasicPhysicsPlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -362,6 +362,16 @@ namespace OpenSim.Region.Physics.BulletDotNETPlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -397,6 +397,16 @@ namespace OpenSim.Region.Physics.BulletDotNETPlugin
//TODO: //TODO:
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {
//TODO: GhostObject //TODO: GhostObject

View File

@ -985,6 +985,16 @@ namespace OpenSim.Region.Physics.BulletXPlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -734,6 +734,16 @@ namespace OpenSim.Region.Physics.OdePlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -287,6 +287,16 @@ namespace OpenSim.Region.Physics.OdePlugin
}//end ProcessRotationVehicleParam }//end ProcessRotationVehicleParam
internal void ProcessFlagsVehicleSet(int flags)
{
m_flags |= (VehicleFlag)flags;
}
internal void ProcessFlagsVehicleRemove(int flags)
{
m_flags &= ~((VehicleFlag)flags);
}
internal void ProcessTypeChange(Vehicle pType) internal void ProcessTypeChange(Vehicle pType)
{ {
// Set Defaults For Type // Set Defaults For Type

View File

@ -2416,6 +2416,16 @@ Console.WriteLine(" JointCreateFixed");
m_vehicle.ProcessRotationVehicleParam((Vehicle) param, rotation); m_vehicle.ProcessRotationVehicleParam((Vehicle) param, rotation);
} }
public override void VehicleFlagsSet(int flags)
{
m_vehicle.ProcessFlagsVehicleSet(flags);
}
public override void VehicleFlagsRemove(int flags)
{
m_vehicle.ProcessFlagsVehicleRemove(flags);
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {
lock (_parent_scene.OdeLock) lock (_parent_scene.OdeLock)

View File

@ -208,6 +208,8 @@ namespace OpenSim.Region.Physics.Manager
public abstract void VehicleFloatParam(int param, float value); public abstract void VehicleFloatParam(int param, float value);
public abstract void VehicleVectorParam(int param, Vector3 value); public abstract void VehicleVectorParam(int param, Vector3 value);
public abstract void VehicleRotationParam(int param, Quaternion rotation); public abstract void VehicleRotationParam(int param, Quaternion rotation);
public abstract void VehicleFlagsSet(int flags);
public abstract void VehicleFlagsRemove(int flags);
public abstract void SetVolumeDetect(int param); // Allows the detection of collisions with inherently non-physical prims. see llVolumeDetect for more public abstract void SetVolumeDetect(int param); // Allows the detection of collisions with inherently non-physical prims. see llVolumeDetect for more
@ -352,6 +354,16 @@ namespace OpenSim.Region.Physics.Manager
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -734,6 +734,16 @@ namespace OpenSim.Region.Physics.OdePlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -2353,6 +2353,16 @@ Console.WriteLine(" JointCreateFixed");
m_vehicle.ProcessRotationVehicleParam((Vehicle) param, rotation); m_vehicle.ProcessRotationVehicleParam((Vehicle) param, rotation);
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {
lock (_parent_scene.OdeLock) lock (_parent_scene.OdeLock)

View File

@ -182,6 +182,16 @@ namespace OpenSim.Region.Physics.POSPlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -139,6 +139,16 @@ namespace OpenSim.Region.Physics.POSPlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -371,6 +371,16 @@ namespace OpenSim.Region.Physics.PhysXPlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {
@ -775,6 +785,16 @@ namespace OpenSim.Region.Physics.PhysXPlugin
} }
public override void VehicleFlagsSet(int flags)
{
}
public override void VehicleFlagsRemove(int flags)
{
}
public override void SetVolumeDetect(int param) public override void SetVolumeDetect(int param)
{ {

View File

@ -6315,13 +6315,25 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
public void llSetVehicleFlags(int flags) public void llSetVehicleFlags(int flags)
{ {
m_host.AddScriptLPS(1); m_host.AddScriptLPS(1);
NotImplemented("llSetVehicleFlags"); if (m_host.ParentGroup != null)
{
if (!m_host.ParentGroup.IsDeleted)
{
m_host.ParentGroup.RootPart.SetVehicleFlags(flags);
}
}
} }
public void llRemoveVehicleFlags(int flags) public void llRemoveVehicleFlags(int flags)
{ {
m_host.AddScriptLPS(1); m_host.AddScriptLPS(1);
NotImplemented("llRemoveVehicleFlags"); if (m_host.ParentGroup != null)
{
if (!m_host.ParentGroup.IsDeleted)
{
m_host.ParentGroup.RootPart.RemoveVehicleFlags(flags);
}
}
} }
public void llSitTarget(LSL_Vector offset, LSL_Rotation rot) public void llSitTarget(LSL_Vector offset, LSL_Rotation rot)