From c0ba99e5ada0b734b932091befce69dbd53d149a Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Thu, 15 Dec 2011 22:29:36 +0000 Subject: Stop having to call SetHeight again in ScenePresence.AddToPhysicalScene() when we've already passed size information to the avatar at PhysicsScene.AddAvatar() Eliminate some copypasta for height setting in OdeCharacter --- OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs | 3 ++- OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsScene.cs | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'OpenSim/Region/Physics/BasicPhysicsPlugin') diff --git a/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs b/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs index 5e2eeeb..1e1d5e3 100644 --- a/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs +++ b/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs @@ -44,8 +44,9 @@ namespace OpenSim.Region.Physics.BasicPhysicsPlugin private bool flying; private bool iscolliding; - public BasicActor() + public BasicActor(Vector3 size) { + Size = size; } public override int PhysicsActorType diff --git a/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsScene.cs b/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsScene.cs index 1ceed1a..2e14216 100644 --- a/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsScene.cs +++ b/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsScene.cs @@ -56,7 +56,7 @@ namespace OpenSim.Region.Physics.BasicPhysicsPlugin } public override PhysicsActor AddAvatar(string avName, Vector3 position, Vector3 size, bool isFlying) { - BasicActor act = new BasicActor(); + BasicActor act = new BasicActor(size); act.Position = position; act.Flying = isFlying; _actors.Add(act); -- cgit v1.1 From 41b02a7208a8363f8edefb812e4f93238759d2bd Mon Sep 17 00:00:00 2001 From: Dan Lake Date: Tue, 20 Dec 2011 14:45:32 -0800 Subject: Remove unused SetAcceleration and add set on Acceleration parameter --- OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'OpenSim/Region/Physics/BasicPhysicsPlugin') diff --git a/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs b/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs index 1e1d5e3..b1a3ff9 100644 --- a/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs +++ b/OpenSim/Region/Physics/BasicPhysicsPlugin/BasicPhysicsActor.cs @@ -233,6 +233,7 @@ namespace OpenSim.Region.Physics.BasicPhysicsPlugin public override Vector3 Acceleration { get { return _acceleration; } + set { _acceleration = value; } } public override bool Kinematic @@ -253,11 +254,6 @@ namespace OpenSim.Region.Physics.BasicPhysicsPlugin { } - public void SetAcceleration(Vector3 accel) - { - _acceleration = accel; - } - public override void AddForce(Vector3 force, bool pushforce) { } -- cgit v1.1