From 445fb51455f7218a62133dbb28d2a2cae60c9472 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Wed, 13 Jul 2016 22:35:46 +0100 Subject: [PATCH] make getBoundsCenter() call GetBoundsRadius() to do the math if needed --- OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs index 722905f23f..d556fd18ed 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs @@ -1576,9 +1576,12 @@ namespace OpenSim.Region.Framework.Scenes private Vector3 m_boundsCenter; public Vector3 getBoundsCenter() { - // this needs to be called after GetBoundsRadius() so its updated + // math is done in GetBoundsRadius(); + if(m_boundsRadius == null) + GetBoundsRadius(); return m_boundsCenter; } + public float GetBoundsRadius() { // this may need more threading work