本文整理汇总了C#中OpenSim.Framework.RegionInfo.SetEndPoint方法的典型用法代码示例。如果您正苦于以下问题:C# RegionInfo.SetEndPoint方法的具体用法?C# RegionInfo.SetEndPoint怎么用?C# RegionInfo.SetEndPoint使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类OpenSim.Framework.RegionInfo
的用法示例。
在下文中一共展示了RegionInfo.SetEndPoint方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GetRegionInfo
public RegionInfo GetRegionInfo(string regionName)
{
List<string> RetVal = GD.Query("RegionName", regionName, "simulator", "*");
RegionInfo replyData = new RegionInfo();
if (RetVal.Count == 0)
return null;
int i = 0;
for (i = 0; i < RetVal.Count; i++)
{
if (i == 0)
replyData.RegionID = new UUID(RetVal[i]);
if (i == 1)
replyData.RegionName = RetVal[i];
if (i == 2)
replyData.RegionLocX = uint.Parse(RetVal[i]);
if (i == 3)
replyData.RegionLocY = uint.Parse(RetVal[i]);
if (i == 6)
replyData.ExternalHostName = RetVal[i];
if (i == 7)
replyData.RegionType = RetVal[i];
if (i == 11)
replyData.ObjectCapacity = Convert.ToInt32(RetVal[i]);
if (i == 15)
replyData.AccessLevel = Convert.ToByte(RetVal[i]);
if (i == 16)
replyData.Disabled = int.Parse(RetVal[i]) == 1;
if (i == 17)
replyData.AllowScriptCrossing = int.Parse(RetVal[i]) == 1;
if (i == 18)
replyData.TrustBinariesFromForeignSims = int.Parse(RetVal[i]) == 1;
if (i == 19)
replyData.SeeIntoThisSimFromNeighbor = int.Parse(RetVal[i]) == 1;
if (i == 20)
{
replyData.AllowPhysicalPrims = int.Parse(RetVal[i]) == 1;
replyData.SetEndPoint(RetVal[4], int.Parse(RetVal[5]));
if (replyData.ExternalHostName == "DEFAULT")
{
replyData.ExternalHostName = Aurora.Framework.Utilities.GetExternalIp();
}
replyData.HttpPort = uint.Parse(RetVal[5]);
}
}
return replyData;
}
示例2: GetRegionInfos
public RegionInfo[] GetRegionInfos()
{
List<RegionInfo> Infos = new List<RegionInfo>();
List<string> RetVal = GD.Query("Disabled", false, "simulator", "*");
if (RetVal.Count == 0)
return Infos.ToArray();
int DataCount = 0;
RegionInfo replyData = new RegionInfo();
for (int i = 0; i < RetVal.Count; i++)
{
if (DataCount == 0)
replyData.RegionID = new UUID(RetVal[i]);
if (DataCount == 1)
replyData.RegionName = RetVal[i];
if (DataCount == 2)
replyData.RegionLocX = uint.Parse(RetVal[i]);
if (DataCount == 3)
replyData.RegionLocY = uint.Parse(RetVal[i]);
if (DataCount == 6)
replyData.ExternalHostName = RetVal[i];
if (DataCount == 7)
replyData.RegionType = RetVal[i];
if (DataCount == 11)
replyData.ObjectCapacity = Convert.ToInt32(RetVal[i]);
if (DataCount == 15)
replyData.AccessLevel = Convert.ToByte(RetVal[i]);
if (DataCount == 16)
replyData.Disabled = int.Parse(RetVal[i]) == 1;
if (DataCount == 17)
replyData.AllowScriptCrossing = int.Parse(RetVal[i]) == 1;
if (DataCount == 18)
replyData.TrustBinariesFromForeignSims = int.Parse(RetVal[i]) == 1;
if (DataCount == 19)
replyData.SeeIntoThisSimFromNeighbor = int.Parse(RetVal[i]) == 1;
if (DataCount == 20)
replyData.AllowPhysicalPrims = int.Parse(RetVal[i]) == 1;
DataCount++;
if (DataCount == 21)
{
replyData.SetEndPoint(RetVal[(i - (DataCount - 1)) + 4], int.Parse(RetVal[(i - (DataCount - 1)) + 5]));
if (replyData.ExternalHostName == "DEFAULT")
{
replyData.ExternalHostName = Aurora.Framework.Utilities.GetExternalIp();
}
replyData.HttpPort = uint.Parse(RetVal[(i - (DataCount - 1)) + 5]);
DataCount = 0;
Infos.Add(replyData);
replyData = new RegionInfo();
}
}
return Infos.ToArray();
}