don't break child agents start position
parent
e0878864e8
commit
5bb5eb4e37
|
@ -4240,16 +4240,18 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
// CleanDroppedAttachments();
|
// CleanDroppedAttachments();
|
||||||
// }
|
// }
|
||||||
|
|
||||||
// Make sure avatar position is in the region (why it wouldn't be is a mystery but do sanity checking)
|
if(teleportFlags != (uint) TPFlags.Default)
|
||||||
if (acd.startpos.X < 0)
|
{
|
||||||
acd.startpos.X = 1f;
|
// Make sure root avatar position is in the region
|
||||||
else if (acd.startpos.X >= RegionInfo.RegionSizeX)
|
if (acd.startpos.X < 0)
|
||||||
acd.startpos.X = RegionInfo.RegionSizeX - 1f;
|
acd.startpos.X = 1f;
|
||||||
if (acd.startpos.Y < 0)
|
else if (acd.startpos.X >= RegionInfo.RegionSizeX)
|
||||||
acd.startpos.Y = 1f;
|
acd.startpos.X = RegionInfo.RegionSizeX - 1f;
|
||||||
else if (acd.startpos.Y >= RegionInfo.RegionSizeY)
|
if (acd.startpos.Y < 0)
|
||||||
acd.startpos.Y = RegionInfo.RegionSizeY - 1f;
|
acd.startpos.Y = 1f;
|
||||||
|
else if (acd.startpos.Y >= RegionInfo.RegionSizeY)
|
||||||
|
acd.startpos.Y = RegionInfo.RegionSizeY - 1f;
|
||||||
|
}
|
||||||
// only check access, actual relocations will happen later on ScenePresence MakeRoot
|
// only check access, actual relocations will happen later on ScenePresence MakeRoot
|
||||||
// allow child agents creation
|
// allow child agents creation
|
||||||
if(!godlike && teleportFlags != (uint) TPFlags.Default)
|
if(!godlike && teleportFlags != (uint) TPFlags.Default)
|
||||||
|
|
Loading…
Reference in New Issue