aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorCharles Krinke2008-09-28 22:38:59 +0000
committerCharles Krinke2008-09-28 22:38:59 +0000
commit6758ecc40375fb046f142f5f45a19513a89b1f86 (patch)
treead96c1b2674d2124952ca63e4ec60a2703ed7945 /OpenSim
parentMantis#2291. Thank you kindly, StrawberryFride for a patch that solves: (diff)
downloadopensim-SC-6758ecc40375fb046f142f5f45a19513a89b1f86.zip
opensim-SC-6758ecc40375fb046f142f5f45a19513a89b1f86.tar.gz
opensim-SC-6758ecc40375fb046f142f5f45a19513a89b1f86.tar.bz2
opensim-SC-6758ecc40375fb046f142f5f45a19513a89b1f86.tar.xz
Implement the plumbing for llSetVehicleType from the LSL
subroutine down through the physics modules through PhysActor and SceneObjectPart. No connection to the physics simulators.
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneObjectPart.cs8
-rw-r--r--OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsPlugin.cs6
-rw-r--r--OpenSim/Region/Physics/BulletXPlugin/BulletXPlugin.cs6
-rw-r--r--OpenSim/Region/Physics/Manager/PhysicsActor.cs7
-rw-r--r--OpenSim/Region/Physics/OdePlugin/ODECharacter.cs6
-rw-r--r--OpenSim/Region/Physics/OdePlugin/ODEPrim.cs6
-rw-r--r--OpenSim/Region/Physics/POSPlugin/POSCharacter.cs6
-rw-r--r--OpenSim/Region/Physics/POSPlugin/POSPrim.cs6
-rw-r--r--OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs12
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs8
10 files changed, 70 insertions, 1 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
index 68df0e4..17d678d 100644
--- a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
@@ -2337,6 +2337,14 @@ namespace OpenSim.Region.Environment.Scenes
2337 } 2337 }
2338 } 2338 }
2339 2339
2340 public void SetVehicleType(int type)
2341 {
2342 if (PhysActor != null)
2343 {
2344 PhysActor.VehicleType = type;
2345 }
2346 }
2347
2340 public void SetVehicleFloatParam(int param, float value) 2348 public void SetVehicleFloatParam(int param, float value)
2341 { 2349 {
2342 if (PhysActor != null) 2350 if (PhysActor != null)
diff --git a/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsPlugin.cs b/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsPlugin.cs
index 96543da..702f5f1 100644
--- a/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsPlugin.cs
+++ b/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsPlugin.cs
@@ -335,6 +335,12 @@ namespace OpenSim.Region.Physics.BasicPhysicsPlugin
335 set { return; } 335 set { return; }
336 } 336 }
337 337
338 public override int VehicleType
339 {
340 get { return 0; }
341 set { return; }
342 }
343
338 public override void VehicleFloatParam(int param, float value) 344 public override void VehicleFloatParam(int param, float value)
339 { 345 {
340 346
diff --git a/OpenSim/Region/Physics/BulletXPlugin/BulletXPlugin.cs b/OpenSim/Region/Physics/BulletXPlugin/BulletXPlugin.cs
index e62f966..9e7b459 100644
--- a/OpenSim/Region/Physics/BulletXPlugin/BulletXPlugin.cs
+++ b/OpenSim/Region/Physics/BulletXPlugin/BulletXPlugin.cs
@@ -950,6 +950,12 @@ namespace OpenSim.Region.Physics.BulletXPlugin
950 set { return; } 950 set { return; }
951 } 951 }
952 952
953 public override int VehicleType
954 {
955 get { return 0; }
956 set { return; }
957 }
958
953 public override void VehicleFloatParam(int param, float value) 959 public override void VehicleFloatParam(int param, float value)
954 { 960 {
955 961
diff --git a/OpenSim/Region/Physics/Manager/PhysicsActor.cs b/OpenSim/Region/Physics/Manager/PhysicsActor.cs
index 44d4df7..5b51203 100644
--- a/OpenSim/Region/Physics/Manager/PhysicsActor.cs
+++ b/OpenSim/Region/Physics/Manager/PhysicsActor.cs
@@ -175,6 +175,7 @@ namespace OpenSim.Region.Physics.Manager
175 public abstract float Mass { get; } 175 public abstract float Mass { get; }
176 public abstract PhysicsVector Force { get; set; } 176 public abstract PhysicsVector Force { get; set; }
177 177
178 public abstract int VehicleType { get; set; }
178 public abstract void VehicleFloatParam(int param, float value); 179 public abstract void VehicleFloatParam(int param, float value);
179 public abstract void VehicleVectorParam(int param, PhysicsVector value); 180 public abstract void VehicleVectorParam(int param, PhysicsVector value);
180 public abstract void VehicleRotationParam(int param, Quaternion rotation); 181 public abstract void VehicleRotationParam(int param, Quaternion rotation);
@@ -281,6 +282,12 @@ namespace OpenSim.Region.Physics.Manager
281 set { return; } 282 set { return; }
282 } 283 }
283 284
285 public override int VehicleType
286 {
287 get { return 0; }
288 set { return; }
289 }
290
284 public override void VehicleFloatParam(int param, float value) 291 public override void VehicleFloatParam(int param, float value)
285 { 292 {
286 293
diff --git a/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs b/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs
index 6af0781..2561fa5 100644
--- a/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs
+++ b/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs
@@ -537,6 +537,12 @@ namespace OpenSim.Region.Physics.OdePlugin
537 set { return; } 537 set { return; }
538 } 538 }
539 539
540 public override int VehicleType
541 {
542 get { return 0; }
543 set { return; }
544 }
545
540 public override void VehicleFloatParam(int param, float value) 546 public override void VehicleFloatParam(int param, float value)
541 { 547 {
542 548
diff --git a/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs b/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
index 9db7e8b..5d9b169 100644
--- a/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
+++ b/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
@@ -1876,6 +1876,12 @@ namespace OpenSim.Region.Physics.OdePlugin
1876 set { m_force = value; } 1876 set { m_force = value; }
1877 } 1877 }
1878 1878
1879 public override int VehicleType
1880 {
1881 get { return 0; }
1882 set { return; }
1883 }
1884
1879 public override void VehicleFloatParam(int param, float value) 1885 public override void VehicleFloatParam(int param, float value)
1880 { 1886 {
1881 1887
diff --git a/OpenSim/Region/Physics/POSPlugin/POSCharacter.cs b/OpenSim/Region/Physics/POSPlugin/POSCharacter.cs
index 9719a05..a9ddf27 100644
--- a/OpenSim/Region/Physics/POSPlugin/POSCharacter.cs
+++ b/OpenSim/Region/Physics/POSPlugin/POSCharacter.cs
@@ -159,6 +159,12 @@ namespace OpenSim.Region.Physics.POSPlugin
159 set { return; } 159 set { return; }
160 } 160 }
161 161
162 public override int VehicleType
163 {
164 get { return 0; }
165 set { return; }
166 }
167
162 public override void VehicleFloatParam(int param, float value) 168 public override void VehicleFloatParam(int param, float value)
163 { 169 {
164 170
diff --git a/OpenSim/Region/Physics/POSPlugin/POSPrim.cs b/OpenSim/Region/Physics/POSPlugin/POSPrim.cs
index 265e170..873529e 100644
--- a/OpenSim/Region/Physics/POSPlugin/POSPrim.cs
+++ b/OpenSim/Region/Physics/POSPlugin/POSPrim.cs
@@ -121,6 +121,12 @@ namespace OpenSim.Region.Physics.POSPlugin
121 set { return; } 121 set { return; }
122 } 122 }
123 123
124 public override int VehicleType
125 {
126 get { return 0; }
127 set { return; }
128 }
129
124 public override void VehicleFloatParam(int param, float value) 130 public override void VehicleFloatParam(int param, float value)
125 { 131 {
126 132
diff --git a/OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs b/OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs
index c9d2c13..2d35ff0 100644
--- a/OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs
+++ b/OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs
@@ -343,6 +343,12 @@ namespace OpenSim.Region.Physics.PhysXPlugin
343 set { return; } 343 set { return; }
344 } 344 }
345 345
346 public override int VehicleType
347 {
348 get { return 0; }
349 set { return; }
350 }
351
346 public override void VehicleFloatParam(int param, float value) 352 public override void VehicleFloatParam(int param, float value)
347 { 353 {
348 354
@@ -688,6 +694,12 @@ namespace OpenSim.Region.Physics.PhysXPlugin
688 set { return; } 694 set { return; }
689 } 695 }
690 696
697 public override int VehicleType
698 {
699 get { return 0; }
700 set { return; }
701 }
702
691 public override void VehicleFloatParam(int param, float value) 703 public override void VehicleFloatParam(int param, float value)
692 { 704 {
693 705
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index e560d52..540ff98 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -5159,7 +5159,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
5159 public void llSetVehicleType(int type) 5159 public void llSetVehicleType(int type)
5160 { 5160 {
5161 m_host.AddScriptLPS(1); 5161 m_host.AddScriptLPS(1);
5162 NotImplemented("llSetVehicleType"); 5162 if (m_host.ParentGroup != null)
5163 {
5164 if (m_host.ParentGroup.RootPart != null)
5165 {
5166 m_host.ParentGroup.RootPart.SetVehicleType(type);
5167 }
5168 }
5163 } 5169 }
5164 5170
5165 //CFK 9/28: Most, but not all of the underlying plumbing between here and the physics modules is in 5171 //CFK 9/28: Most, but not all of the underlying plumbing between here and the physics modules is in