mirror of
https://github.com/opensim/opensim.git
synced 2026-08-01 14:16:07 +08:00
Partial port of Avination's support for the new physics parameters.
Implements the parameters as properties, the serialization and database storage (MySQL only). Implements llSetPrimitiveParams for prim physics shape and the other 4 extra params. Only the prim shape type "None" is currently functional. No support for the Viewer UI (yet), that will be ported in due course. Lots more to port, this is a large-ish changeset.
This commit is contained in:
@@ -7594,6 +7594,22 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
||||
part.ScriptSetPhysicsStatus(physics);
|
||||
break;
|
||||
|
||||
case (int)ScriptBaseClass.PRIM_PHYSICS_SHAPE_TYPE:
|
||||
if (remain < 1)
|
||||
return null;
|
||||
|
||||
int shape_type = rules.GetLSLIntegerItem(idx++);
|
||||
|
||||
ExtraPhysicsData physdata = new ExtraPhysicsData();
|
||||
physdata.Density = part.Density;
|
||||
physdata.Bounce = part.Bounciness;
|
||||
physdata.GravitationModifier = part.GravityModifier;
|
||||
physdata.PhysShapeType = (PhysShapeType)shape_type;
|
||||
|
||||
part.UpdateExtraPhysics(physdata);
|
||||
|
||||
break;
|
||||
|
||||
case (int)ScriptBaseClass.PRIM_TEMP_ON_REZ:
|
||||
if (remain < 1)
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user