From c4ddaf67cb31517c3d5e379d0237a21d1d7b2c9d Mon Sep 17 00:00:00 2001 From: prep Date: Thu, 1 Mar 2012 17:33:45 -0500 Subject: path-264: Locking avatar in place when pathing floater is up. --- indra/newview/llagent.cpp | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'indra/newview/llagent.cpp') diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index ab9b5ff436..657e464cbb 100755 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -88,6 +88,7 @@ #include "llworld.h" #include "llworldmap.h" #include "stringize.h" +#include "llfloaterpathfindingconsole.h" using namespace LLVOAvatarDefines; @@ -399,6 +400,12 @@ void LLAgent::ageChat() //----------------------------------------------------------------------------- void LLAgent::moveAt(S32 direction, bool reset) { + LLFloaterPathfindingConsole* pWindow = LLFloaterPathfindingConsole::getInstanceHandle().get(); + if ( pWindow && pWindow->getHeartBeat() ) + { + return; + } + mMoveTimer.reset(); LLFirstUse::notMoving(false); @@ -427,6 +434,11 @@ void LLAgent::moveAt(S32 direction, bool reset) //----------------------------------------------------------------------------- void LLAgent::moveAtNudge(S32 direction) { + LLFloaterPathfindingConsole* pWindow = LLFloaterPathfindingConsole::getInstanceHandle().get(); + if ( pWindow && pWindow->getHeartBeat() ) + { + return; + } mMoveTimer.reset(); LLFirstUse::notMoving(false); @@ -648,6 +660,12 @@ void LLAgent::setFlying(BOOL fly) // static void LLAgent::toggleFlying() { + LLFloaterPathfindingConsole* pWindow = LLFloaterPathfindingConsole::getInstanceHandle().get(); + if ( pWindow && pWindow->getHeartBeat() ) + { + return; + } + if ( gAgent.mAutoPilot ) { LLToolPie::instance().stopClickToWalk(); @@ -2706,6 +2724,12 @@ void LLAgent::sendAnimationRequest(const LLUUID &anim_id, EAnimRequest request) void LLAgent::sendWalkRun(bool running) { + LLFloaterPathfindingConsole* pWindow = LLFloaterPathfindingConsole::getInstanceHandle().get(); + if ( pWindow->getHeartBeat() ) + { + return; + } + LLMessageSystem* msgsys = gMessageSystem; if (msgsys) { -- cgit v1.2.3