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/Framework/Scenes/ScenePresence.cs | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
(limited to 'OpenSim/Region/Framework/Scenes/ScenePresence.cs')
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
index 6f5b6fe..ac58dae 100644
--- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
@@ -1149,13 +1149,11 @@ namespace OpenSim.Region.Framework.Scenes
///
/// Sets avatar height in the physics plugin
///
+ /// New height of avatar
public void SetHeight(float height)
{
if (PhysicsActor != null && !IsChildAgent)
- {
- Vector3 SetSize = new Vector3(0.45f, 0.6f, height);
- PhysicsActor.Size = SetSize;
- }
+ PhysicsActor.Size = new Vector3(0.45f, 0.6f, height);
}
///
@@ -3273,8 +3271,6 @@ namespace OpenSim.Region.Framework.Scenes
PhysicsActor.OnOutOfBounds += OutOfBoundsCall; // Called for PhysicsActors when there's something wrong
PhysicsActor.SubscribeEvents(500);
PhysicsActor.LocalID = LocalId;
-
- SetHeight(Appearance.AvatarHeight);
}
private void OutOfBoundsCall(Vector3 pos)
--
cgit v1.1