Add a bunch of fixes to the world and minimap so that teleports inside a var work and the map looks semi-correct.

Conflicts:

	indra/newview/app_settings/message_template.msg
This commit is contained in:
Siana Gearz
2011-10-06 02:32:50 +02:00
parent 00196ca439
commit df7f37d0eb
8 changed files with 76 additions and 26 deletions

View File

@@ -3582,7 +3582,7 @@ void LLAgent::teleportViaLocation(const LLVector3d& pos_global)
(F32)(pos_global.mdV[VY] - region_origin.mdV[VY]),
(F32)(pos_global.mdV[VZ]));
pos_local += offset;
teleportRequest(handle, pos_local);
teleportRequest(info->getHandle(), pos_local);
}
else if(regionp &&
teleportCore(regionp->getHandle() == to_region_handle_global((F32)pos_global.mdV[VX], (F32)pos_global.mdV[VY])))
@@ -3631,6 +3631,10 @@ void LLAgent::teleportViaLocationLookAt(const LLVector3d& pos_global)
mbTeleportKeepsLookAt = true;
gAgentCamera.setFocusOnAvatar(FALSE, ANIMATE); // detach camera form avatar, so it keeps direction
U64 region_handle = to_region_handle(pos_global);
LLSimInfo* simInfo = LLWorldMap::instance().simInfoFromHandle(region_handle);
if(simInfo)
region_handle = simInfo->getHandle();
LLVector3 pos_local = (LLVector3)(pos_global - from_region_handle(region_handle));
teleportRequest(region_handle, pos_local, getTeleportKeepsLookAt());
}