summaryrefslogtreecommitdiff
path: root/indra/newview/llagentui.cpp
diff options
context:
space:
mode:
authorangela <angela@lindenlab.com>2009-11-04 12:33:52 +0800
committerangela <angela@lindenlab.com>2009-11-04 12:33:52 +0800
commit61603ca9d55c76219093cb7000e7f75e539bf5fe (patch)
treeb1528b99061758e0f7b8fdaaa8754c2169036d89 /indra/newview/llagentui.cpp
parent1190b5d9eb6f1e1d698430957b99872abd354f81 (diff)
parent6e9fe077277b50634b125084f52da55fa8cb84d9 (diff)
mergre
Diffstat (limited to 'indra/newview/llagentui.cpp')
-rw-r--r--indra/newview/llagentui.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/indra/newview/llagentui.cpp b/indra/newview/llagentui.cpp
index 2911a35581..09f7c49f23 100644
--- a/indra/newview/llagentui.cpp
+++ b/indra/newview/llagentui.cpp
@@ -92,10 +92,7 @@ std::string LLAgentUI::buildSLURL(const bool escaped /*= true*/)
//static
BOOL LLAgentUI::checkAgentDistance(const LLVector3& pole, F32 radius)
{
- F32 delta_x = gAgent.getPositionAgent().mV[VX] - pole.mV[VX];
- F32 delta_y = gAgent.getPositionAgent().mV[VY] - pole.mV[VY];
-
- return sqrt( delta_x* delta_x + delta_y* delta_y ) < radius;
+ return (gAgent.getPositionAgent() - pole).length() < radius;
}
BOOL LLAgentUI::buildLocationString(std::string& str, ELocationFormat fmt,const LLVector3& agent_pos_region)
{