From 187e36f6c51e78b00802af7f1758496993365bf0 Mon Sep 17 00:00:00 2001 From: McCabe Maxsted Date: Fri, 11 Sep 2009 17:25:17 -0700 Subject: Applied patch for long distance opensim hypergrid tps (SVC-2491) (Feature currently disabled in OpenSim) --- linden/indra/newview/llviewermessage.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'linden/indra/newview/llviewermessage.cpp') diff --git a/linden/indra/newview/llviewermessage.cpp b/linden/indra/newview/llviewermessage.cpp index 3fb8e9a..e4de5b4 100644 --- a/linden/indra/newview/llviewermessage.cpp +++ b/linden/indra/newview/llviewermessage.cpp @@ -2718,6 +2718,10 @@ void process_agent_movement_complete(LLMessageSystem* msg, void**) // appropriate. LLVector3 shift_vector = regionp->getPosRegionFromGlobal( gAgent.getRegion()->getOriginGlobal()); + // don't shift objects, if teleporting more than about 1000 sims, as + // for long teleports shifting objects garbles the view at the target region + if (shift_vector.lengthSquared() > 6.5e10f) + shift_vector = LLVector3::zero; gAgent.setRegion(regionp); gObjectList.shiftObjects(shift_vector); gAssetStorage->setUpstream(msg->getSender()); -- cgit v1.1