mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 09:45:47 +08:00
When preparing a Hypergrid teleport, tell the receiving grid which user is entering the grid.
This can affect which region to use. E.g., returning users may be allowed to enter any region, whereas users from other grids will have to enter a gateway region. Previously per-user decisions were only made later, but by then it's too late to change which region the user enters.
This commit is contained in:
@@ -688,8 +688,7 @@ namespace OpenSim.Services.LLLoginService
|
||||
if (parts.Length > 1)
|
||||
UInt32.TryParse(parts[1], out port);
|
||||
|
||||
// GridRegion region = FindForeignRegion(domainName, port, regionName, out gatekeeper);
|
||||
region = FindForeignRegion(domainName, port, regionName, out gatekeeper);
|
||||
region = FindForeignRegion(domainName, port, regionName, account, out gatekeeper);
|
||||
return region;
|
||||
}
|
||||
}
|
||||
@@ -738,7 +737,7 @@ namespace OpenSim.Services.LLLoginService
|
||||
return null;
|
||||
}
|
||||
|
||||
private GridRegion FindForeignRegion(string domainName, uint port, string regionName, out GridRegion gatekeeper)
|
||||
private GridRegion FindForeignRegion(string domainName, uint port, string regionName, UserAccount account, out GridRegion gatekeeper)
|
||||
{
|
||||
m_log.Debug("[LLLOGIN SERVICE]: attempting to findforeignregion " + domainName + ":" + port.ToString() + ":" + regionName);
|
||||
gatekeeper = new GridRegion();
|
||||
@@ -753,7 +752,11 @@ namespace OpenSim.Services.LLLoginService
|
||||
string message;
|
||||
if (m_GatekeeperConnector.LinkRegion(gatekeeper, out regionID, out handle, out domainName, out imageURL, out reason))
|
||||
{
|
||||
GridRegion destination = m_GatekeeperConnector.GetHyperlinkRegion(gatekeeper, regionID, out message);
|
||||
string homeURI = null;
|
||||
if (account.ServiceURLs != null && account.ServiceURLs.ContainsKey("HomeURI"))
|
||||
homeURI = (string)account.ServiceURLs["HomeURI"];
|
||||
|
||||
GridRegion destination = m_GatekeeperConnector.GetHyperlinkRegion(gatekeeper, regionID, account.PrincipalID, homeURI, out message);
|
||||
return destination;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user