aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/PhysXPlugin
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Physics/PhysXPlugin')
-rw-r--r--OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs133
1 files changed, 85 insertions, 48 deletions
diff --git a/OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs b/OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs
index 7a43a0a..5483703 100644
--- a/OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs
+++ b/OpenSim/Region/Physics/PhysXPlugin/PhysXPlugin.cs
@@ -291,15 +291,23 @@ namespace OpenSim.Region.Physics.PhysXPlugin
291 gravityAccel = 0; 291 gravityAccel = 0;
292 } 292 }
293 } 293 }
294 294 public override PrimitiveBaseShape Shape
295 public void UpdatePosition()
296 { 295 {
297 Vec3 vec = _character.Position; 296 set
298 _position.X = vec.X; 297 {
299 _position.Y = vec.Y; 298 return;
300 _position.Z = vec.Z; 299 }
301 } 300 }
302 } 301
302 public void UpdatePosition()
303 {
304 Vec3 vec = this._character.Position;
305 this._position.X = vec.X;
306 this._position.Y = vec.Y;
307 this._position.Z = vec.Z;
308 }
309 }
310
303 311
304 public class PhysXPrim : PhysicsActor 312 public class PhysXPrim : PhysicsActor
305 { 313 {
@@ -358,55 +366,84 @@ namespace OpenSim.Region.Physics.PhysXPlugin
358 } 366 }
359 } 367 }
360 368
361 public override PhysicsVector Size 369 public override PrimitiveBaseShape Shape
362 { 370 {
363 get { return new PhysicsVector(0, 0, 0); } 371 set
364 set { }
365 }
366
367 public override PhysicsVector Velocity
368 {
369 get { return _velocity; }
370 set { _velocity = value; }
371 }
372
373 public override bool Kinematic
374 {
375 get { return _prim.Kinematic; }
376 set { _prim.Kinematic = value; }
377 }
378
379 public override Quaternion Orientation
380 {
381 get
382 { 372 {
383 Quaternion res = new Quaternion(); 373 return;
384 PhysXWrapper.Quaternion quat = _prim.GetOrientation();
385 res.w = quat.W;
386 res.x = quat.X;
387 res.y = quat.Y;
388 res.z = quat.Z;
389 return res;
390 } 374 }
391 set { }
392 }
393
394 public override PhysicsVector Acceleration
395 {
396 get { return _acceleration; }
397 } 375 }
398 376
399 public void SetAcceleration(PhysicsVector accel) 377 public override PhysicsVector Velocity
400 { 378 {
401 _acceleration = accel; 379 get
402 } 380 {
381 return _velocity;
382 }
383 set
384 {
385 _velocity = value;
386 }
387 }
388
389 public override bool Kinematic
390 {
391 get
392 {
393 return this._prim.Kinematic;
394 }
395 set
396 {
397 this._prim.Kinematic = value;
398 }
399 }
400
401 public override Quaternion Orientation
402 {
403 get
404 {
405 Quaternion res = new Quaternion();
406 PhysXWrapper.Quaternion quat = this._prim.GetOrientation();
407 res.w = quat.W;
408 res.x = quat.X;
409 res.y = quat.Y;
410 res.z = quat.Z;
411 return res;
412 }
413 set
414 {
415
416 }
417 }
418
419 public override PhysicsVector Acceleration
420 {
421 get
422 {
423 return _acceleration;
424 }
425
426 }
427 public void SetAcceleration (PhysicsVector accel)
428 {
429 this._acceleration = accel;
430 }
431
432 public override void AddForce(PhysicsVector force)
433 {
434
435 }
436
437 public override void SetMomentum(PhysicsVector momentum)
438 {
439
440 }
403 441
404 public override void AddForce(PhysicsVector force) 442 public override PhysicsVector Size
405 { 443 {
444 get { return new PhysicsVector(0, 0, 0); }
445 set { }
406 } 446 }
407 447
408 public override void SetMomentum(PhysicsVector momentum)
409 {
410 }
411 } 448 }
412} 449}