Fix teleporting into the non-SW 256x256 corner of a megaregion, though currently with a 10 second delay before auto-reteleport to the correct location.

This now does a check for border crossing (required to trigger the teleport) immediately in SP.MakeRootAgent().
If left any later, it looks like the physics scene changes the position and stops the cross happening.
If done any earlier, nothing happens because the cross-code currently requires a PhysicsActor to be in place, thuogh it's probably not necessary for this case.
user_profiles
Justin Clark-Casey (justincc) 2013-03-23 00:47:59 +00:00
parent 93206ef0fa
commit 01636ca900
1 changed files with 7 additions and 0 deletions

View File

@ -925,6 +925,13 @@ namespace OpenSim.Region.Framework.Scenes
AddToPhysicalScene(isFlying);
// XXX: This is to trigger any secondary teleport needed for a megaregion when the user has teleported to a
// location outside the 'root region' (the south-west 256x256 corner). This is the earlist we can do it
// since it requires a physics actor to be present. If it is left any later, then physics appears to reset
// the value to a negative position which does not trigger the border cross.
// This may not be the best location for this.
CheckForBorderCrossing();
if (ForceFly)
{
Flying = true;