Added support so that during the loading of a xml link list, it checks if a linked hypergrid region's real location is within 4096,4096 map spaces of its "local" location. If it is outside of that range ( so it wouldn't be possible to teleport to it) then it ignores it and doesn't create a link.
See the hypergrid wiki page for more details.0.6.2-post-fixes
parent
eb5a022981
commit
e21b3bf390
|
@ -267,11 +267,14 @@ namespace OpenSim
|
|||
uint xloc, yloc;
|
||||
uint externalPort;
|
||||
string externalHostName;
|
||||
uint realXLoc, realYLoc;
|
||||
|
||||
xloc = Convert.ToUInt32(config.GetString("xloc", "0"));
|
||||
yloc = Convert.ToUInt32(config.GetString("yloc", "0"));
|
||||
externalPort = Convert.ToUInt32(config.GetString("externalPort", "0"));
|
||||
externalHostName = config.GetString("externalHostName", "");
|
||||
realXLoc = Convert.ToUInt32(config.GetString("real-xloc", "0"));
|
||||
realYLoc = Convert.ToUInt32(config.GetString("real-yloc", "0"));
|
||||
|
||||
if (m_enableAutoMapping)
|
||||
{
|
||||
|
@ -279,11 +282,14 @@ namespace OpenSim
|
|||
yloc = (uint)((yloc % 100) + m_autoMappingY);
|
||||
}
|
||||
|
||||
if (((realXLoc == 0) && (realYLoc == 0)) || (((realXLoc - xloc < 3896) || (xloc - realXLoc < 3896)) && ((realYLoc - yloc < 3896) || (yloc - realYLoc < 3896))))
|
||||
{
|
||||
if (TryCreateLink(xloc, yloc, externalPort, externalHostName, out regInfo))
|
||||
{
|
||||
regInfo.RegionName = config.GetString("localName", "");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private bool TryCreateLink(uint xloc, uint yloc, uint externalPort, string externalHostName, out RegionInfo regInfo)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue