make sure login last location is within the region

This commit is contained in:
UbitUmarov 2024-02-13 19:52:41 +00:00
parent 854f6723ac
commit cc3adba92a
1 changed files with 2 additions and 0 deletions

View File

@ -721,6 +721,8 @@ namespace OpenSim.Services.LLLoginService
else
{
position = pinfo.LastPosition;
position.X = Util.Clamp(position.X, 0.5f, region.RegionSizeX - 0.5f);
position.Y = Util.Clamp(position.Y, 0.5f, region.RegionSizeY - 0.5f);
lookAt = pinfo.LastLookAt;
}