Add llGetPhysicsMaterial
parent
d982d24938
commit
4904d40138
|
@ -7851,6 +7851,18 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
|||
}
|
||||
}
|
||||
|
||||
public LSL_List llGetPhysicsMaterial()
|
||||
{
|
||||
LSL_List result = new LSL_List();
|
||||
|
||||
result.Add(new LSL_Float(m_host.GravityModifier));
|
||||
result.Add(new LSL_Float(m_host.Restitution));
|
||||
result.Add(new LSL_Float(m_host.Friction));
|
||||
result.Add(new LSL_Float(m_host.Density));
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
private void SetPhysicsMaterial(SceneObjectPart part, int material_bits,
|
||||
float material_density, float material_friction,
|
||||
float material_restitution, float material_gravity_modifier)
|
||||
|
|
|
@ -433,5 +433,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Interfaces
|
|||
void SetPrimitiveParamsEx(LSL_Key prim, LSL_List rules, string originFunc);
|
||||
void llSetKeyframedMotion(LSL_List frames, LSL_List options);
|
||||
LSL_List GetPrimitiveParamsEx(LSL_Key prim, LSL_List rules);
|
||||
LSL_List llGetPhysicsMaterial();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2009,5 +2009,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
|
|||
{
|
||||
m_LSL_Functions.llSetPhysicsMaterial(material_bits, material_gravity_modifier, material_restitution, material_friction, material_density);
|
||||
}
|
||||
|
||||
public LSL_List llGetPhysicsMaterial()
|
||||
{
|
||||
return m_LSL_Functions.llGetPhysicsMaterial();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue