One can now get hyoergrid region co-ordinates with llRequestSimulatorData
parent
4d44f2d248
commit
a1b64db942
|
@ -9053,7 +9053,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
|||
|
||||
GridRegion info;
|
||||
|
||||
if (m_ScriptEngine.World.RegionInfo.RegionName == simulator)
|
||||
if (m_ScriptEngine.World.RegionInfo.RegionName == simulator) //Det data for this simulator?
|
||||
|
||||
info = new GridRegion(m_ScriptEngine.World.RegionInfo);
|
||||
else
|
||||
info = m_ScriptEngine.World.GridService.GetRegionByName(m_ScriptEngine.World.RegionInfo.ScopeID, simulator);
|
||||
|
@ -9066,10 +9067,25 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
|||
ScriptSleep(1000);
|
||||
return UUID.Zero.ToString();
|
||||
}
|
||||
if (m_ScriptEngine.World.RegionInfo.RegionName != simulator)
|
||||
{
|
||||
//Hypergrid Region co-ordinates
|
||||
uint rx = 0, ry = 0;
|
||||
Utils.LongToUInts(Convert.ToUInt64(info.RegionSecret), out rx, out ry);
|
||||
|
||||
reply = new LSL_Vector(
|
||||
rx,
|
||||
ry,
|
||||
0).ToString();
|
||||
}
|
||||
else
|
||||
{
|
||||
//Local-cooridnates
|
||||
reply = new LSL_Vector(
|
||||
info.RegionLocX,
|
||||
info.RegionLocY,
|
||||
0).ToString();
|
||||
}
|
||||
break;
|
||||
case ScriptBaseClass.DATA_SIM_STATUS:
|
||||
if (info != null)
|
||||
|
|
Loading…
Reference in New Issue