diff options
Diffstat (limited to '')
30 files changed, 228 insertions, 111 deletions
diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index f1290b9..c4de81e 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs | |||
@@ -1293,7 +1293,7 @@ namespace OpenSim.Framework | |||
1293 | void SendViewerEffect(ViewerEffectPacket.EffectBlock[] effectBlocks); | 1293 | void SendViewerEffect(ViewerEffectPacket.EffectBlock[] effectBlocks); |
1294 | void SendViewerTime(int phase); | 1294 | void SendViewerTime(int phase); |
1295 | 1295 | ||
1296 | void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] charterMember, string flAbout, | 1296 | void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] membershipType, string flAbout, |
1297 | uint flags, UUID flImageID, UUID imageID, string profileURL, UUID partnerID); | 1297 | uint flags, UUID flImageID, UUID imageID, string profileURL, UUID partnerID); |
1298 | 1298 | ||
1299 | void SendScriptQuestion(UUID taskID, string taskName, string ownerName, UUID itemID, int question); | 1299 | void SendScriptQuestion(UUID taskID, string taskName, string ownerName, UUID itemID, int question); |
diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs index ca17793..8f754a5 100644 --- a/OpenSim/Framework/RegionInfo.cs +++ b/OpenSim/Framework/RegionInfo.cs | |||
@@ -138,8 +138,6 @@ namespace OpenSim.Framework | |||
138 | protected uint m_httpPort; | 138 | protected uint m_httpPort; |
139 | protected string m_serverURI; | 139 | protected string m_serverURI; |
140 | protected string m_regionName = String.Empty; | 140 | protected string m_regionName = String.Empty; |
141 | protected bool Allow_Alternate_Ports; | ||
142 | public bool m_allow_alternate_ports; | ||
143 | protected string m_externalHostName; | 141 | protected string m_externalHostName; |
144 | protected IPEndPoint m_internalEndPoint; | 142 | protected IPEndPoint m_internalEndPoint; |
145 | protected uint m_remotingPort; | 143 | protected uint m_remotingPort; |
@@ -147,6 +145,7 @@ namespace OpenSim.Framework | |||
147 | public string RemotingAddress; | 145 | public string RemotingAddress; |
148 | public UUID ScopeID = UUID.Zero; | 146 | public UUID ScopeID = UUID.Zero; |
149 | private UUID m_maptileStaticUUID = UUID.Zero; | 147 | private UUID m_maptileStaticUUID = UUID.Zero; |
148 | private bool m_resolveAddress = false; | ||
150 | 149 | ||
151 | public uint WorldLocX = 0; | 150 | public uint WorldLocX = 0; |
152 | public uint WorldLocY = 0; | 151 | public uint WorldLocY = 0; |
@@ -544,7 +543,7 @@ namespace OpenSim.Framework | |||
544 | 543 | ||
545 | private void ReadNiniConfig(IConfigSource source, string name) | 544 | private void ReadNiniConfig(IConfigSource source, string name) |
546 | { | 545 | { |
547 | // bool creatingNew = false; | 546 | bool creatingNew = false; |
548 | 547 | ||
549 | if (source.Configs.Count == 0) | 548 | if (source.Configs.Count == 0) |
550 | { | 549 | { |
@@ -568,7 +567,7 @@ namespace OpenSim.Framework | |||
568 | 567 | ||
569 | source.AddConfig(name); | 568 | source.AddConfig(name); |
570 | 569 | ||
571 | // creatingNew = true; | 570 | creatingNew = true; |
572 | } | 571 | } |
573 | 572 | ||
574 | if (name == String.Empty) | 573 | if (name == String.Empty) |
@@ -672,18 +671,19 @@ namespace OpenSim.Framework | |||
672 | } | 671 | } |
673 | m_internalEndPoint = new IPEndPoint(address, port); | 672 | m_internalEndPoint = new IPEndPoint(address, port); |
674 | 673 | ||
675 | // AllowAlternatePorts | 674 | // ResolveAddress |
676 | // | 675 | // |
677 | allKeys.Remove("AllowAlternatePorts"); | 676 | allKeys.Remove("ResolveAddress"); |
678 | if (config.Contains("AllowAlternatePorts")) | 677 | if (config.Contains("ResolveAddress")) |
679 | { | 678 | { |
680 | m_allow_alternate_ports = config.GetBoolean("AllowAlternatePorts", true); | 679 | m_resolveAddress = config.GetBoolean("ResolveAddress", false); |
681 | } | 680 | } |
682 | else | 681 | else |
683 | { | 682 | { |
684 | m_allow_alternate_ports = Convert.ToBoolean(MainConsole.Instance.CmdPrompt("Allow alternate ports", "False")); | 683 | if (creatingNew) |
684 | m_resolveAddress = Convert.ToBoolean(MainConsole.Instance.CmdPrompt("Resolve hostname to IP on start (for running inside Docker)", "False")); | ||
685 | 685 | ||
686 | config.Set("AllowAlternatePorts", m_allow_alternate_ports.ToString()); | 686 | config.Set("ResolveAddress", m_resolveAddress.ToString()); |
687 | } | 687 | } |
688 | 688 | ||
689 | // ExternalHostName | 689 | // ExternalHostName |
@@ -706,10 +706,18 @@ namespace OpenSim.Framework | |||
706 | "[REGIONINFO]: Resolving SYSTEMIP to {0} for external hostname of region {1}", | 706 | "[REGIONINFO]: Resolving SYSTEMIP to {0} for external hostname of region {1}", |
707 | m_externalHostName, name); | 707 | m_externalHostName, name); |
708 | } | 708 | } |
709 | else | 709 | else if (!m_resolveAddress) |
710 | { | 710 | { |
711 | m_externalHostName = externalName; | 711 | m_externalHostName = externalName; |
712 | } | 712 | } |
713 | else | ||
714 | { | ||
715 | IPAddress[] addrs = Dns.GetHostAddresses(externalName); | ||
716 | if (addrs.Length != 1) // If it is ambiguous or not resolveable, use it literally | ||
717 | m_externalHostName = externalName; | ||
718 | else | ||
719 | m_externalHostName = addrs[0].ToString(); | ||
720 | } | ||
713 | 721 | ||
714 | // RegionType | 722 | // RegionType |
715 | m_regionType = config.GetString("RegionType", String.Empty); | 723 | m_regionType = config.GetString("RegionType", String.Empty); |
@@ -901,8 +909,6 @@ namespace OpenSim.Framework | |||
901 | config.Set("InternalAddress", m_internalEndPoint.Address.ToString()); | 909 | config.Set("InternalAddress", m_internalEndPoint.Address.ToString()); |
902 | config.Set("InternalPort", m_internalEndPoint.Port); | 910 | config.Set("InternalPort", m_internalEndPoint.Port); |
903 | 911 | ||
904 | config.Set("AllowAlternatePorts", m_allow_alternate_ports.ToString()); | ||
905 | |||
906 | config.Set("ExternalHostName", m_externalHostName); | 912 | config.Set("ExternalHostName", m_externalHostName); |
907 | 913 | ||
908 | if (m_nonphysPrimMin > 0) | 914 | if (m_nonphysPrimMin > 0) |
@@ -995,10 +1001,6 @@ namespace OpenSim.Framework | |||
995 | configMember.addConfigurationOption("internal_ip_port", ConfigurationOption.ConfigurationTypes.TYPE_INT32, | 1001 | configMember.addConfigurationOption("internal_ip_port", ConfigurationOption.ConfigurationTypes.TYPE_INT32, |
996 | "Internal IP Port for incoming UDP client connections", | 1002 | "Internal IP Port for incoming UDP client connections", |
997 | m_internalEndPoint.Port.ToString(), true); | 1003 | m_internalEndPoint.Port.ToString(), true); |
998 | configMember.addConfigurationOption("allow_alternate_ports", | ||
999 | ConfigurationOption.ConfigurationTypes.TYPE_BOOLEAN, | ||
1000 | "Allow sim to find alternate UDP ports when ports are in use?", | ||
1001 | m_allow_alternate_ports.ToString(), true); | ||
1002 | configMember.addConfigurationOption("external_host_name", | 1004 | configMember.addConfigurationOption("external_host_name", |
1003 | ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, | 1005 | ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, |
1004 | "External Host Name", m_externalHostName, true); | 1006 | "External Host Name", m_externalHostName, true); |
@@ -1068,9 +1070,6 @@ namespace OpenSim.Framework | |||
1068 | configMember.addConfigurationOption("internal_ip_port", ConfigurationOption.ConfigurationTypes.TYPE_INT32, | 1070 | configMember.addConfigurationOption("internal_ip_port", ConfigurationOption.ConfigurationTypes.TYPE_INT32, |
1069 | "Internal IP Port for incoming UDP client connections", | 1071 | "Internal IP Port for incoming UDP client connections", |
1070 | ConfigSettings.DefaultRegionHttpPort.ToString(), false); | 1072 | ConfigSettings.DefaultRegionHttpPort.ToString(), false); |
1071 | configMember.addConfigurationOption("allow_alternate_ports", ConfigurationOption.ConfigurationTypes.TYPE_BOOLEAN, | ||
1072 | "Allow sim to find alternate UDP ports when ports are in use?", | ||
1073 | "false", true); | ||
1074 | configMember.addConfigurationOption("external_host_name", | 1073 | configMember.addConfigurationOption("external_host_name", |
1075 | ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, | 1074 | ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, |
1076 | "External Host Name", "127.0.0.1", false); | 1075 | "External Host Name", "127.0.0.1", false); |
@@ -1141,9 +1140,6 @@ namespace OpenSim.Framework | |||
1141 | case "internal_ip_port": | 1140 | case "internal_ip_port": |
1142 | m_internalEndPoint.Port = (int) configuration_result; | 1141 | m_internalEndPoint.Port = (int) configuration_result; |
1143 | break; | 1142 | break; |
1144 | case "allow_alternate_ports": | ||
1145 | m_allow_alternate_ports = (bool) configuration_result; | ||
1146 | break; | ||
1147 | case "external_host_name": | 1143 | case "external_host_name": |
1148 | if ((string) configuration_result != "SYSTEMIP") | 1144 | if ((string) configuration_result != "SYSTEMIP") |
1149 | { | 1145 | { |
@@ -1220,7 +1216,6 @@ namespace OpenSim.Framework | |||
1220 | if ((RemotingAddress != null) && !RemotingAddress.Equals("")) | 1216 | if ((RemotingAddress != null) && !RemotingAddress.Equals("")) |
1221 | args["remoting_address"] = OSD.FromString(RemotingAddress); | 1217 | args["remoting_address"] = OSD.FromString(RemotingAddress); |
1222 | args["remoting_port"] = OSD.FromString(RemotingPort.ToString()); | 1218 | args["remoting_port"] = OSD.FromString(RemotingPort.ToString()); |
1223 | args["allow_alt_ports"] = OSD.FromBoolean(m_allow_alternate_ports); | ||
1224 | if ((proxyUrl != null) && !proxyUrl.Equals("")) | 1219 | if ((proxyUrl != null) && !proxyUrl.Equals("")) |
1225 | args["proxy_url"] = OSD.FromString(proxyUrl); | 1220 | args["proxy_url"] = OSD.FromString(proxyUrl); |
1226 | if (RegionType != String.Empty) | 1221 | if (RegionType != String.Empty) |
@@ -1275,8 +1270,6 @@ namespace OpenSim.Framework | |||
1275 | RemotingAddress = args["remoting_address"].AsString(); | 1270 | RemotingAddress = args["remoting_address"].AsString(); |
1276 | if (args["remoting_port"] != null) | 1271 | if (args["remoting_port"] != null) |
1277 | UInt32.TryParse(args["remoting_port"].AsString(), out m_remotingPort); | 1272 | UInt32.TryParse(args["remoting_port"].AsString(), out m_remotingPort); |
1278 | if (args["allow_alt_ports"] != null) | ||
1279 | m_allow_alternate_ports = args["allow_alt_ports"].AsBoolean(); | ||
1280 | if (args["proxy_url"] != null) | 1273 | if (args["proxy_url"] != null) |
1281 | proxyUrl = args["proxy_url"].AsString(); | 1274 | proxyUrl = args["proxy_url"].AsString(); |
1282 | if (args["region_type"] != null) | 1275 | if (args["region_type"] != null) |
@@ -1314,7 +1307,8 @@ namespace OpenSim.Framework | |||
1314 | kvp["http_port"] = HttpPort.ToString(); | 1307 | kvp["http_port"] = HttpPort.ToString(); |
1315 | kvp["internal_ip_address"] = InternalEndPoint.Address.ToString(); | 1308 | kvp["internal_ip_address"] = InternalEndPoint.Address.ToString(); |
1316 | kvp["internal_port"] = InternalEndPoint.Port.ToString(); | 1309 | kvp["internal_port"] = InternalEndPoint.Port.ToString(); |
1317 | kvp["alternate_ports"] = m_allow_alternate_ports.ToString(); | 1310 | // TODO: Remove in next major version |
1311 | kvp["alternate_ports"] = "False"; | ||
1318 | kvp["server_uri"] = ServerURI; | 1312 | kvp["server_uri"] = ServerURI; |
1319 | 1313 | ||
1320 | return kvp; | 1314 | return kvp; |
diff --git a/OpenSim/Framework/Util.cs b/OpenSim/Framework/Util.cs index 01a06cd..a6fd99f 100644 --- a/OpenSim/Framework/Util.cs +++ b/OpenSim/Framework/Util.cs | |||
@@ -1685,6 +1685,8 @@ namespace OpenSim.Framework | |||
1685 | 1685 | ||
1686 | // hide the password in the connection string | 1686 | // hide the password in the connection string |
1687 | passPosition = connectionString.IndexOf("password", StringComparison.OrdinalIgnoreCase); | 1687 | passPosition = connectionString.IndexOf("password", StringComparison.OrdinalIgnoreCase); |
1688 | if (passPosition == -1) | ||
1689 | return connectionString; | ||
1688 | passPosition = connectionString.IndexOf("=", passPosition); | 1690 | passPosition = connectionString.IndexOf("=", passPosition); |
1689 | if (passPosition < connectionString.Length) | 1691 | if (passPosition < connectionString.Length) |
1690 | passPosition += 1; | 1692 | passPosition += 1; |
diff --git a/OpenSim/Region/Application/OpenSim.cs b/OpenSim/Region/Application/OpenSim.cs index cf2bf33..3cb999b 100644 --- a/OpenSim/Region/Application/OpenSim.cs +++ b/OpenSim/Region/Application/OpenSim.cs | |||
@@ -26,6 +26,7 @@ | |||
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System; | 28 | using System; |
29 | using System.Threading; | ||
29 | using System.Collections; | 30 | using System.Collections; |
30 | using System.Collections.Generic; | 31 | using System.Collections.Generic; |
31 | using System.Diagnostics; | 32 | using System.Diagnostics; |
@@ -74,7 +75,7 @@ namespace OpenSim | |||
74 | 75 | ||
75 | private string m_timedScript = "disabled"; | 76 | private string m_timedScript = "disabled"; |
76 | private int m_timeInterval = 1200; | 77 | private int m_timeInterval = 1200; |
77 | private Timer m_scriptTimer; | 78 | private System.Timers.Timer m_scriptTimer; |
78 | 79 | ||
79 | public OpenSim(IConfigSource configSource) : base(configSource) | 80 | public OpenSim(IConfigSource configSource) : base(configSource) |
80 | { | 81 | { |
@@ -125,6 +126,21 @@ namespace OpenSim | |||
125 | m_log.Info("[OPENSIM MAIN]: Using async_call_method " + Util.FireAndForgetMethod); | 126 | m_log.Info("[OPENSIM MAIN]: Using async_call_method " + Util.FireAndForgetMethod); |
126 | } | 127 | } |
127 | 128 | ||
129 | private static Mono.Unix.UnixSignal[] signals; | ||
130 | |||
131 | |||
132 | private Thread signal_thread = new Thread (delegate () | ||
133 | { | ||
134 | while (true) | ||
135 | { | ||
136 | // Wait for a signal to be delivered | ||
137 | int index = Mono.Unix.UnixSignal.WaitAny (signals, -1); | ||
138 | |||
139 | //Mono.Unix.Native.Signum signal = signals [index].Signum; | ||
140 | MainConsole.Instance.RunCommand("shutdown"); | ||
141 | } | ||
142 | }); | ||
143 | |||
128 | /// <summary> | 144 | /// <summary> |
129 | /// Performs initialisation of the scene, such as loading configuration from disk. | 145 | /// Performs initialisation of the scene, such as loading configuration from disk. |
130 | /// </summary> | 146 | /// </summary> |
@@ -134,6 +150,24 @@ namespace OpenSim | |||
134 | m_log.Info("========================= STARTING OPENSIM ========================="); | 150 | m_log.Info("========================= STARTING OPENSIM ========================="); |
135 | m_log.Info("===================================================================="); | 151 | m_log.Info("===================================================================="); |
136 | 152 | ||
153 | if(!Util.IsWindows()) | ||
154 | { | ||
155 | try | ||
156 | { | ||
157 | // linux mac os specifics | ||
158 | signals = new Mono.Unix.UnixSignal[] | ||
159 | { | ||
160 | new Mono.Unix.UnixSignal(Mono.Unix.Native.Signum.SIGTERM) | ||
161 | }; | ||
162 | signal_thread.Start(); | ||
163 | } | ||
164 | catch (Exception e) | ||
165 | { | ||
166 | m_log.Info("Could not set up UNIX signal handlers. SIGTERM will not"); | ||
167 | m_log.InfoFormat("shut down gracefully: {0}", e.Message); | ||
168 | m_log.Debug("Exception was: ", e); | ||
169 | } | ||
170 | } | ||
137 | //m_log.InfoFormat("[OPENSIM MAIN]: GC Is Server GC: {0}", GCSettings.IsServerGC.ToString()); | 171 | //m_log.InfoFormat("[OPENSIM MAIN]: GC Is Server GC: {0}", GCSettings.IsServerGC.ToString()); |
138 | // http://msdn.microsoft.com/en-us/library/bb384202.aspx | 172 | // http://msdn.microsoft.com/en-us/library/bb384202.aspx |
139 | //GCSettings.LatencyMode = GCLatencyMode.Batch; | 173 | //GCSettings.LatencyMode = GCLatencyMode.Batch; |
@@ -217,7 +251,7 @@ namespace OpenSim | |||
217 | // Start timer script (run a script every xx seconds) | 251 | // Start timer script (run a script every xx seconds) |
218 | if (m_timedScript != "disabled") | 252 | if (m_timedScript != "disabled") |
219 | { | 253 | { |
220 | m_scriptTimer = new Timer(); | 254 | m_scriptTimer = new System.Timers.Timer(); |
221 | m_scriptTimer.Enabled = true; | 255 | m_scriptTimer.Enabled = true; |
222 | m_scriptTimer.Interval = m_timeInterval*1000; | 256 | m_scriptTimer.Interval = m_timeInterval*1000; |
223 | m_scriptTimer.Elapsed += RunAutoTimerScript; | 257 | m_scriptTimer.Elapsed += RunAutoTimerScript; |
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index ce7ee98..a69b670 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs | |||
@@ -2704,7 +2704,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
2704 | OutPacket(packet, ThrottleOutPacketType.Task); | 2704 | OutPacket(packet, ThrottleOutPacketType.Task); |
2705 | } | 2705 | } |
2706 | 2706 | ||
2707 | public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] charterMember, | 2707 | public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] membershipType, |
2708 | string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, | 2708 | string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, |
2709 | UUID partnerID) | 2709 | UUID partnerID) |
2710 | { | 2710 | { |
@@ -2716,7 +2716,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
2716 | else | 2716 | else |
2717 | avatarReply.PropertiesData.AboutText = Utils.EmptyBytes; | 2717 | avatarReply.PropertiesData.AboutText = Utils.EmptyBytes; |
2718 | avatarReply.PropertiesData.BornOn = Util.StringToBytes256(bornOn); | 2718 | avatarReply.PropertiesData.BornOn = Util.StringToBytes256(bornOn); |
2719 | avatarReply.PropertiesData.CharterMember = charterMember; | 2719 | avatarReply.PropertiesData.CharterMember = membershipType; |
2720 | if (flAbout != null) | 2720 | if (flAbout != null) |
2721 | avatarReply.PropertiesData.FLAboutText = Util.StringToBytes256(flAbout); | 2721 | avatarReply.PropertiesData.FLAboutText = Util.StringToBytes256(flAbout); |
2722 | else | 2722 | else |
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs index a868e3a..cedb9b4 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs | |||
@@ -81,7 +81,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
81 | uint port = (uint)scene.RegionInfo.InternalEndPoint.Port; | 81 | uint port = (uint)scene.RegionInfo.InternalEndPoint.Port; |
82 | 82 | ||
83 | IPAddress listenIP = scene.RegionInfo.InternalEndPoint.Address; | 83 | IPAddress listenIP = scene.RegionInfo.InternalEndPoint.Address; |
84 | Initialise(listenIP, ref port, scene.RegionInfo.ProxyOffset, scene.RegionInfo.m_allow_alternate_ports, m_Config, scene.AuthenticateHandler); | 84 | Initialise(listenIP, ref port, scene.RegionInfo.ProxyOffset, m_Config, scene.AuthenticateHandler); |
85 | scene.RegionInfo.InternalEndPoint.Port = (int)port; | 85 | scene.RegionInfo.InternalEndPoint.Port = (int)port; |
86 | 86 | ||
87 | AddScene(scene); | 87 | AddScene(scene); |
@@ -98,9 +98,9 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
98 | } | 98 | } |
99 | #endregion | 99 | #endregion |
100 | 100 | ||
101 | public virtual void Initialise(IPAddress listenIP, ref uint port, int proxyPortOffsetParm, bool allow_alternate_port, IConfigSource configSource, AgentCircuitManager circuitManager) | 101 | public virtual void Initialise(IPAddress listenIP, ref uint port, int proxyPortOffsetParm, IConfigSource configSource, AgentCircuitManager circuitManager) |
102 | { | 102 | { |
103 | m_udpServer = new LLUDPServer(listenIP, ref port, proxyPortOffsetParm, allow_alternate_port, configSource, circuitManager); | 103 | m_udpServer = new LLUDPServer(listenIP, ref port, proxyPortOffsetParm, configSource, circuitManager); |
104 | } | 104 | } |
105 | 105 | ||
106 | public virtual void AddScene(IScene scene) | 106 | public virtual void AddScene(IScene scene) |
@@ -430,12 +430,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
430 | public JobEngine OqrEngine { get; protected set; } | 430 | public JobEngine OqrEngine { get; protected set; } |
431 | 431 | ||
432 | public LLUDPServer( | 432 | public LLUDPServer( |
433 | IPAddress listenIP, ref uint port, int proxyPortOffsetParm, bool allow_alternate_port, | 433 | IPAddress listenIP, ref uint port, int proxyPortOffsetParm, |
434 | IConfigSource configSource, AgentCircuitManager circuitManager) | 434 | IConfigSource configSource, AgentCircuitManager circuitManager) |
435 | : base(listenIP, (int)port) | 435 | : base(listenIP, (int)port) |
436 | { | 436 | { |
437 | #region Environment.TickCount Measurement | 437 | #region Environment.TickCount Measurement |
438 | 438 | ||
439 | // Update the port with the one we actually got | ||
440 | port = (uint)Port; | ||
441 | |||
439 | // Measure the resolution of Environment.TickCount | 442 | // Measure the resolution of Environment.TickCount |
440 | TickCountResolution = 0f; | 443 | TickCountResolution = 0f; |
441 | for (int i = 0; i < 10; i++) | 444 | for (int i = 0; i < 10; i++) |
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/OpenSimUDPBase.cs b/OpenSim/Region/ClientStack/Linden/UDP/OpenSimUDPBase.cs index 4d726b4..831381e 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/OpenSimUDPBase.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/OpenSimUDPBase.cs | |||
@@ -107,6 +107,11 @@ namespace OpenMetaverse | |||
107 | /// </summary> | 107 | /// </summary> |
108 | public float AverageReceiveTicksForLastSamplePeriod { get; private set; } | 108 | public float AverageReceiveTicksForLastSamplePeriod { get; private set; } |
109 | 109 | ||
110 | public int Port | ||
111 | { | ||
112 | get { return m_udpPort; } | ||
113 | } | ||
114 | |||
110 | #region PacketDropDebugging | 115 | #region PacketDropDebugging |
111 | /// <summary> | 116 | /// <summary> |
112 | /// For debugging purposes only... random number generator for dropping | 117 | /// For debugging purposes only... random number generator for dropping |
@@ -217,10 +222,6 @@ namespace OpenMetaverse | |||
217 | SocketType.Dgram, | 222 | SocketType.Dgram, |
218 | ProtocolType.Udp); | 223 | ProtocolType.Udp); |
219 | 224 | ||
220 | // OpenSim may need this but in AVN, this messes up automated | ||
221 | // sim restarts badly | ||
222 | //m_udpSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, false); | ||
223 | |||
224 | try | 225 | try |
225 | { | 226 | { |
226 | if (m_udpSocket.Ttl < 128) | 227 | if (m_udpSocket.Ttl < 128) |
@@ -248,13 +249,22 @@ namespace OpenMetaverse | |||
248 | // we never want two regions to listen on the same port as they cannot demultiplex each other's messages, | 249 | // we never want two regions to listen on the same port as they cannot demultiplex each other's messages, |
249 | // leading to a confusing bug. | 250 | // leading to a confusing bug. |
250 | // By default, Windows does not allow two sockets to bind to the same port. | 251 | // By default, Windows does not allow two sockets to bind to the same port. |
251 | m_udpSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, false); | 252 | // |
253 | // Unfortunately, this also causes a crashed sim to leave the socket in a state | ||
254 | // where it appears to be in use but is really just hung from the old process | ||
255 | // crashing rather than closing it. While this protects agains misconfiguration, | ||
256 | // allowing crashed sims to be started up again right away, rather than having to | ||
257 | // wait 2 minutes for the socket to clear is more valuable. Commented 12/13/2016 | ||
258 | // m_udpSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReuseAddress, false); | ||
252 | 259 | ||
253 | if (recvBufferSize != 0) | 260 | if (recvBufferSize != 0) |
254 | m_udpSocket.ReceiveBufferSize = recvBufferSize; | 261 | m_udpSocket.ReceiveBufferSize = recvBufferSize; |
255 | 262 | ||
256 | m_udpSocket.Bind(ipep); | 263 | m_udpSocket.Bind(ipep); |
257 | 264 | ||
265 | if (m_udpPort == 0) | ||
266 | m_udpPort = ((IPEndPoint)m_udpSocket.LocalEndPoint).Port; | ||
267 | |||
258 | IsRunningInbound = true; | 268 | IsRunningInbound = true; |
259 | 269 | ||
260 | // kick off an async receive. The Start() method will return, the | 270 | // kick off an async receive. The Start() method will return, the |
diff --git a/OpenSim/Region/CoreModules/Avatar/Profile/BasicProfileModule.cs b/OpenSim/Region/CoreModules/Avatar/Profile/BasicProfileModule.cs index 2bb24ae..0b1dbc7 100644 --- a/OpenSim/Region/CoreModules/Avatar/Profile/BasicProfileModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Profile/BasicProfileModule.cs | |||
@@ -154,7 +154,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Profile | |||
154 | name = account.FirstName + " " + account.LastName; | 154 | name = account.FirstName + " " + account.LastName; |
155 | created = account.Created; | 155 | created = account.Created; |
156 | } | 156 | } |
157 | Byte[] charterMember = Utils.StringToBytes(name); | 157 | Byte[] membershipType = Utils.StringToBytes(name); |
158 | 158 | ||
159 | profileUrl = "No profile data"; | 159 | profileUrl = "No profile data"; |
160 | aboutText = string.Empty; | 160 | aboutText = string.Empty; |
@@ -166,7 +166,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Profile | |||
166 | remoteClient.SendAvatarProperties(avatarID, aboutText, | 166 | remoteClient.SendAvatarProperties(avatarID, aboutText, |
167 | Util.ToDateTime(created).ToString( | 167 | Util.ToDateTime(created).ToString( |
168 | "M/d/yyyy", CultureInfo.InvariantCulture), | 168 | "M/d/yyyy", CultureInfo.InvariantCulture), |
169 | charterMember, firstLifeAboutText, | 169 | membershipType, firstLifeAboutText, |
170 | (uint)(0 & 0xff), | 170 | (uint)(0 & 0xff), |
171 | firstLifeImage, image, profileUrl, partner); | 171 | firstLifeImage, image, profileUrl, partner); |
172 | 172 | ||
diff --git a/OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs b/OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs index 5be8556..5314927 100644 --- a/OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs | |||
@@ -1009,9 +1009,9 @@ namespace OpenSim.Region.CoreModules.Avatar.UserProfiles | |||
1009 | 1009 | ||
1010 | if (p != null && p.isNPC) | 1010 | if (p != null && p.isNPC) |
1011 | { | 1011 | { |
1012 | remoteClient.SendAvatarProperties(avatarID, ((INPC)(p.ControllingClient)).profileAbout, "5/25/1977", | 1012 | remoteClient.SendAvatarProperties(avatarID, ((INPC)(p.ControllingClient)).profileAbout, ((INPC)(p.ControllingClient)).Born, |
1013 | Utils.StringToBytes("Non Player Character (NPC)"), "NPCs have no life", 16, | 1013 | Utils.StringToBytes("Non Player Character (NPC)"), "NPCs have no life", 16, |
1014 | UUID.Zero, UUID.Zero, "", UUID.Zero); | 1014 | UUID.Zero, ((INPC)(p.ControllingClient)).profileImage, "", UUID.Zero); |
1015 | remoteClient.SendAvatarInterestsReply(avatarID, 0, "", | 1015 | remoteClient.SendAvatarInterestsReply(avatarID, 0, "", |
1016 | 0, "Getting into trouble", "Droidspeak"); | 1016 | 0, "Getting into trouble", "Droidspeak"); |
1017 | return; | 1017 | return; |
@@ -1032,7 +1032,7 @@ namespace OpenSim.Region.CoreModules.Avatar.UserProfiles | |||
1032 | userInfo = new Dictionary<string, object>(); | 1032 | userInfo = new Dictionary<string, object>(); |
1033 | } | 1033 | } |
1034 | 1034 | ||
1035 | Byte[] charterMember = new Byte[1]; | 1035 | Byte[] membershipType = new Byte[1]; |
1036 | string born = String.Empty; | 1036 | string born = String.Empty; |
1037 | uint flags = 0x00; | 1037 | uint flags = 0x00; |
1038 | 1038 | ||
@@ -1040,11 +1040,11 @@ namespace OpenSim.Region.CoreModules.Avatar.UserProfiles | |||
1040 | { | 1040 | { |
1041 | if (account.UserTitle == "") | 1041 | if (account.UserTitle == "") |
1042 | { | 1042 | { |
1043 | charterMember[0] = (Byte)((account.UserFlags & 0xf00) >> 8); | 1043 | membershipType[0] = (Byte)((account.UserFlags & 0xf00) >> 8); |
1044 | } | 1044 | } |
1045 | else | 1045 | else |
1046 | { | 1046 | { |
1047 | charterMember = Utils.StringToBytes(account.UserTitle); | 1047 | membershipType = Utils.StringToBytes(account.UserTitle); |
1048 | } | 1048 | } |
1049 | 1049 | ||
1050 | born = Util.ToDateTime(account.Created).ToString( | 1050 | born = Util.ToDateTime(account.Created).ToString( |
@@ -1057,11 +1057,11 @@ namespace OpenSim.Region.CoreModules.Avatar.UserProfiles | |||
1057 | { | 1057 | { |
1058 | if ((string)userInfo["user_title"] == "") | 1058 | if ((string)userInfo["user_title"] == "") |
1059 | { | 1059 | { |
1060 | charterMember[0] = (Byte)(((Byte)userInfo["user_flags"] & 0xf00) >> 8); | 1060 | membershipType[0] = (Byte)(((Byte)userInfo["user_flags"] & 0xf00) >> 8); |
1061 | } | 1061 | } |
1062 | else | 1062 | else |
1063 | { | 1063 | { |
1064 | charterMember = Utils.StringToBytes((string)userInfo["user_title"]); | 1064 | membershipType = Utils.StringToBytes((string)userInfo["user_title"]); |
1065 | } | 1065 | } |
1066 | 1066 | ||
1067 | int val_born = (int)userInfo["user_created"]; | 1067 | int val_born = (int)userInfo["user_created"]; |
@@ -1085,7 +1085,7 @@ namespace OpenSim.Region.CoreModules.Avatar.UserProfiles | |||
1085 | return; | 1085 | return; |
1086 | } | 1086 | } |
1087 | 1087 | ||
1088 | remoteClient.SendAvatarProperties(props.UserId, props.AboutText, born, charterMember , props.FirstLifeText, flags, | 1088 | remoteClient.SendAvatarProperties(props.UserId, props.AboutText, born, membershipType , props.FirstLifeText, flags, |
1089 | props.FirstLifeImageId, props.ImageId, props.WebUrl, props.PartnerId); | 1089 | props.FirstLifeImageId, props.ImageId, props.WebUrl, props.PartnerId); |
1090 | 1090 | ||
1091 | 1091 | ||
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs index ad094b4..58d6cf2 100644 --- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs +++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | |||
@@ -456,7 +456,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
456 | } | 456 | } |
457 | 457 | ||
458 | // Check Default Location (Also See ScenePresence.CompleteMovement) | 458 | // Check Default Location (Also See ScenePresence.CompleteMovement) |
459 | if (position.X == 128f && position.Y == 128f) | 459 | if (position.X == 128f && position.Y == 128f && position.Z == 22.5f) |
460 | position = sp.Scene.RegionInfo.DefaultLandingPoint; | 460 | position = sp.Scene.RegionInfo.DefaultLandingPoint; |
461 | 461 | ||
462 | // TODO: Get proper AVG Height | 462 | // TODO: Get proper AVG Height |
diff --git a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs index 98f1f3b..bec5322 100644 --- a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs +++ b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs | |||
@@ -72,8 +72,6 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
72 | 72 | ||
73 | public const int LandUnit = 4; | 73 | public const int LandUnit = 4; |
74 | 74 | ||
75 | private static readonly string remoteParcelRequestPath = "0009/"; | ||
76 | |||
77 | private LandChannel landChannel; | 75 | private LandChannel landChannel; |
78 | private Scene m_scene; | 76 | private Scene m_scene; |
79 | 77 | ||
@@ -1682,12 +1680,13 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
1682 | 1680 | ||
1683 | private void EventManagerOnRegisterCaps(UUID agentID, Caps caps) | 1681 | private void EventManagerOnRegisterCaps(UUID agentID, Caps caps) |
1684 | { | 1682 | { |
1683 | //string capsBase = "/CAPS/" + UUID.Random(); | ||
1685 | string capsBase = "/CAPS/" + caps.CapsObjectPath; | 1684 | string capsBase = "/CAPS/" + caps.CapsObjectPath; |
1686 | caps.RegisterHandler( | 1685 | caps.RegisterHandler( |
1687 | "RemoteParcelRequest", | 1686 | "RemoteParcelRequest", |
1688 | new RestStreamHandler( | 1687 | new RestStreamHandler( |
1689 | "POST", | 1688 | "POST", |
1690 | capsBase + remoteParcelRequestPath, | 1689 | capsBase, |
1691 | (request, path, param, httpRequest, httpResponse) | 1690 | (request, path, param, httpRequest, httpResponse) |
1692 | => RemoteParcelRequest(request, path, param, agentID, caps), | 1691 | => RemoteParcelRequest(request, path, param, agentID, caps), |
1693 | "RemoteParcelRequest", | 1692 | "RemoteParcelRequest", |
@@ -1807,24 +1806,7 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
1807 | ArrayList list = (ArrayList)hash["location"]; | 1806 | ArrayList list = (ArrayList)hash["location"]; |
1808 | uint x = (uint)(double)list[0]; | 1807 | uint x = (uint)(double)list[0]; |
1809 | uint y = (uint)(double)list[1]; | 1808 | uint y = (uint)(double)list[1]; |
1810 | if(hash.ContainsKey("region_id")) | 1809 | if (hash.ContainsKey("region_handle")) |
1811 | { | ||
1812 | UUID regionID = (UUID)hash["region_id"]; | ||
1813 | if (regionID == m_scene.RegionInfo.RegionID) | ||
1814 | { | ||
1815 | // a parcel request for a local parcel => no need to query the grid | ||
1816 | parcelID = Util.BuildFakeParcelID(m_scene.RegionInfo.RegionHandle, x, y); | ||
1817 | } | ||
1818 | else | ||
1819 | { | ||
1820 | // a parcel request for a parcel in another region. Ask the grid about the region | ||
1821 | GridRegion info = m_scene.GridService.GetRegionByUUID(scope, regionID); | ||
1822 | if (info != null) | ||
1823 | parcelID = Util.BuildFakeParcelID(info.RegionHandle, x, y); | ||
1824 | } | ||
1825 | } | ||
1826 | |||
1827 | else if (hash.ContainsKey("region_handle")) | ||
1828 | { | 1810 | { |
1829 | // if you do a "About Landmark" on a landmark a second time, the viewer sends the | 1811 | // if you do a "About Landmark" on a landmark a second time, the viewer sends the |
1830 | // region_handle it got earlier via RegionHandleRequest | 1812 | // region_handle it got earlier via RegionHandleRequest |
@@ -1847,6 +1829,24 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
1847 | } | 1829 | } |
1848 | } | 1830 | } |
1849 | } | 1831 | } |
1832 | else if(hash.ContainsKey("region_id")) | ||
1833 | { | ||
1834 | UUID regionID = (UUID)hash["region_id"]; | ||
1835 | if (regionID == m_scene.RegionInfo.RegionID) | ||
1836 | { | ||
1837 | // a parcel request for a local parcel => no need to query the grid | ||
1838 | parcelID = Util.BuildFakeParcelID(m_scene.RegionInfo.RegionHandle, x, y); | ||
1839 | } | ||
1840 | else | ||
1841 | { | ||
1842 | // a parcel request for a parcel in another region. Ask the grid about the region | ||
1843 | GridRegion info = m_scene.GridService.GetRegionByUUID(scope, regionID); | ||
1844 | if (info != null) | ||
1845 | parcelID = Util.BuildFakeParcelID(info.RegionHandle, x, y); | ||
1846 | } | ||
1847 | } | ||
1848 | |||
1849 | |||
1850 | } | 1850 | } |
1851 | } | 1851 | } |
1852 | catch (LLSD.LLSDParseException e) | 1852 | catch (LLSD.LLSDParseException e) |
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs index d1fe3c7..fb63c6a 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs | |||
@@ -216,7 +216,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
216 | // while we don't fix the hard-coded urls | 216 | // while we don't fix the hard-coded urls |
217 | if (flags == 2) | 217 | if (flags == 2) |
218 | { | 218 | { |
219 | if (regionInfos.Count == 0) | 219 | if (regionInfos == null || regionInfos.Count == 0) |
220 | remoteClient.SendAgentAlertMessage("No regions found with that name.", true); | 220 | remoteClient.SendAgentAlertMessage("No regions found with that name.", true); |
221 | // else if (regionInfos.Count == 1) | 221 | // else if (regionInfos.Count == 1) |
222 | // remoteClient.SendAgentAlertMessage("Region found!", false); | 222 | // remoteClient.SendAgentAlertMessage("Region found!", false); |
diff --git a/OpenSim/Region/Framework/Interfaces/INPCModule.cs b/OpenSim/Region/Framework/Interfaces/INPCModule.cs index 1310358..813be4f 100644 --- a/OpenSim/Region/Framework/Interfaces/INPCModule.cs +++ b/OpenSim/Region/Framework/Interfaces/INPCModule.cs | |||
@@ -59,6 +59,8 @@ namespace OpenSim.Region.Framework.Interfaces | |||
59 | UUID ActiveGroupId { get; set; } | 59 | UUID ActiveGroupId { get; set; } |
60 | UUID Owner { get; } | 60 | UUID Owner { get; } |
61 | string profileAbout { get; set; } | 61 | string profileAbout { get; set; } |
62 | UUID profileImage { get; set; } | ||
63 | string Born { get; set; } | ||
62 | } | 64 | } |
63 | 65 | ||
64 | public interface INPCModule | 66 | public interface INPCModule |
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 2cf0e9d..463f6c8 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -2044,7 +2044,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2044 | } | 2044 | } |
2045 | 2045 | ||
2046 | // Check Default Location (Also See EntityTransferModule.TeleportAgentWithinRegion) | 2046 | // Check Default Location (Also See EntityTransferModule.TeleportAgentWithinRegion) |
2047 | if (AbsolutePosition.X == 128f && AbsolutePosition.Y == 128f) | 2047 | if (AbsolutePosition.X == 128f && AbsolutePosition.Y == 128f && AbsolutePosition.Z == 22.5f) |
2048 | AbsolutePosition = Scene.RegionInfo.DefaultLandingPoint; | 2048 | AbsolutePosition = Scene.RegionInfo.DefaultLandingPoint; |
2049 | 2049 | ||
2050 | if (!MakeRootAgent(AbsolutePosition, flying, ref look)) | 2050 | if (!MakeRootAgent(AbsolutePosition, flying, ref look)) |
@@ -2125,11 +2125,12 @@ namespace OpenSim.Region.Framework.Scenes | |||
2125 | if (!gotCrossUpdate && !isNPC) | 2125 | if (!gotCrossUpdate && !isNPC) |
2126 | Scene.SendLayerData(ControllingClient); | 2126 | Scene.SendLayerData(ControllingClient); |
2127 | 2127 | ||
2128 | // HG delay | 2128 | // HG |
2129 | if((m_teleportFlags & TeleportFlags.ViaHGLogin) != 0) | 2129 | bool isHGTP = (m_teleportFlags & TeleportFlags.ViaHGLogin) != 0; |
2130 | if(isHGTP) | ||
2130 | { | 2131 | { |
2131 | Thread.Sleep(500); | 2132 | // ControllingClient.SendNameReply(m_uuid, Firstname, Lastname); |
2132 | m_log.DebugFormat("[CompleteMovement] HG delay: {0}ms", Util.EnvironmentTickCountSubtract(ts)); | 2133 | m_log.DebugFormat("[CompleteMovement] HG"); |
2133 | } | 2134 | } |
2134 | 2135 | ||
2135 | m_previusParcelHide = false; | 2136 | m_previusParcelHide = false; |
@@ -2151,7 +2152,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2151 | cachedbaked = true; | 2152 | cachedbaked = true; |
2152 | else | 2153 | else |
2153 | { | 2154 | { |
2154 | if (m_scene.AvatarFactory != null) | 2155 | if (m_scene.AvatarFactory != null && !isHGTP) |
2155 | cachedbaked = m_scene.AvatarFactory.ValidateBakedTextureCache(this); | 2156 | cachedbaked = m_scene.AvatarFactory.ValidateBakedTextureCache(this); |
2156 | 2157 | ||
2157 | // not sure we need this | 2158 | // not sure we need this |
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs index 15d31bd..8b8ebe0 100644 --- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs +++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs | |||
@@ -1247,7 +1247,7 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server | |||
1247 | 1247 | ||
1248 | } | 1248 | } |
1249 | 1249 | ||
1250 | public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, byte[] charterMember, string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, UUID partnerID) | 1250 | public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, byte[] membershipType, string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, UUID partnerID) |
1251 | { | 1251 | { |
1252 | 1252 | ||
1253 | } | 1253 | } |
diff --git a/OpenSim/Region/OptionalModules/DataSnapshot/LandSnapshot.cs b/OpenSim/Region/OptionalModules/DataSnapshot/LandSnapshot.cs index 5c791e6..eb2867d 100644 --- a/OpenSim/Region/OptionalModules/DataSnapshot/LandSnapshot.cs +++ b/OpenSim/Region/OptionalModules/DataSnapshot/LandSnapshot.cs | |||
@@ -268,8 +268,12 @@ namespace OpenSim.Region.DataSnapshot.Providers | |||
268 | { | 268 | { |
269 | XmlNode username = nodeFactory.CreateNode(XmlNodeType.Element, "name", ""); | 269 | XmlNode username = nodeFactory.CreateNode(XmlNodeType.Element, "name", ""); |
270 | UserAccount account = m_scene.UserAccountService.GetUserAccount(m_scene.RegionInfo.ScopeID, userOwnerUUID); | 270 | UserAccount account = m_scene.UserAccountService.GetUserAccount(m_scene.RegionInfo.ScopeID, userOwnerUUID); |
271 | username.InnerText = account.FirstName + " " + account.LastName; | 271 | if(account != null) |
272 | username.InnerText = account.FirstName + " " + account.LastName; | ||
273 | else | ||
274 | username.InnerText = "UnKnown"; | ||
272 | userblock.AppendChild(username); | 275 | userblock.AppendChild(username); |
276 | |||
273 | } | 277 | } |
274 | catch (Exception) | 278 | catch (Exception) |
275 | { | 279 | { |
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs index 1096eae..0cabe47 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | |||
@@ -70,6 +70,8 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
70 | private readonly UUID m_ownerID; | 70 | private readonly UUID m_ownerID; |
71 | private UUID m_hostGroupID; | 71 | private UUID m_hostGroupID; |
72 | private string m_profileAbout = ""; | 72 | private string m_profileAbout = ""; |
73 | private UUID m_profileImage = UUID.Zero; | ||
74 | private string m_born; | ||
73 | public List<uint> SelectedObjects {get; private set;} | 75 | public List<uint> SelectedObjects {get; private set;} |
74 | 76 | ||
75 | public NPCAvatar( | 77 | public NPCAvatar( |
@@ -109,6 +111,13 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
109 | m_profileAbout = value; | 111 | m_profileAbout = value; |
110 | } | 112 | } |
111 | } | 113 | } |
114 | |||
115 | public UUID profileImage | ||
116 | { | ||
117 | get { return m_profileImage; } | ||
118 | set { m_profileImage = value; } | ||
119 | } | ||
120 | |||
112 | public IScene Scene | 121 | public IScene Scene |
113 | { | 122 | { |
114 | get { return m_scene; } | 123 | get { return m_scene; } |
@@ -611,6 +620,12 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
611 | set { } | 620 | set { } |
612 | } | 621 | } |
613 | 622 | ||
623 | public string Born | ||
624 | { | ||
625 | get { return m_born; } | ||
626 | set { m_born = value; } | ||
627 | } | ||
628 | |||
614 | public bool IsGroupMember(UUID groupID) | 629 | public bool IsGroupMember(UUID groupID) |
615 | { | 630 | { |
616 | return (m_hostGroupID == groupID); | 631 | return (m_hostGroupID == groupID); |
@@ -974,7 +989,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
974 | { | 989 | { |
975 | } | 990 | } |
976 | 991 | ||
977 | public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] charterMember, | 992 | public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] membershipType, |
978 | string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, | 993 | string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, |
979 | UUID partnerID) | 994 | UUID partnerID) |
980 | { | 995 | { |
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs index 8462661..ced82e6 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCModule.cs | |||
@@ -168,6 +168,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
168 | AvatarAppearance appearance) | 168 | AvatarAppearance appearance) |
169 | { | 169 | { |
170 | NPCAvatar npcAvatar = null; | 170 | NPCAvatar npcAvatar = null; |
171 | string born = DateTime.UtcNow.ToString(); | ||
171 | 172 | ||
172 | try | 173 | try |
173 | { | 174 | { |
@@ -222,6 +223,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
222 | ScenePresence sp; | 223 | ScenePresence sp; |
223 | if (scene.TryGetScenePresence(npcAvatar.AgentId, out sp)) | 224 | if (scene.TryGetScenePresence(npcAvatar.AgentId, out sp)) |
224 | { | 225 | { |
226 | npcAvatar.Born = born; | ||
225 | npcAvatar.ActiveGroupId = groupID; | 227 | npcAvatar.ActiveGroupId = groupID; |
226 | sp.CompleteMovement(npcAvatar, false); | 228 | sp.CompleteMovement(npcAvatar, false); |
227 | sp.Grouptitle = groupTitle; | 229 | sp.Grouptitle = groupTitle; |
diff --git a/OpenSim/Region/PhysicsModules/ubOde/ODEMeshWorker.cs b/OpenSim/Region/PhysicsModules/ubOde/ODEMeshWorker.cs index a977473..bb661e5 100644 --- a/OpenSim/Region/PhysicsModules/ubOde/ODEMeshWorker.cs +++ b/OpenSim/Region/PhysicsModules/ubOde/ODEMeshWorker.cs | |||
@@ -239,7 +239,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde | |||
239 | { | 239 | { |
240 | if (m_scene.haveActor(repData.actor)) | 240 | if (m_scene.haveActor(repData.actor)) |
241 | { | 241 | { |
242 | if (needsMeshing(repData.pbs)) // no need for pbs now? | 242 | if (needsMeshing(repData)) // no need for pbs now? |
243 | { | 243 | { |
244 | repData.comand = meshWorkerCmnds.changefull; | 244 | repData.comand = meshWorkerCmnds.changefull; |
245 | createqueue.Enqueue(repData); | 245 | createqueue.Enqueue(repData); |
@@ -284,8 +284,9 @@ namespace OpenSim.Region.PhysicsModule.ubOde | |||
284 | /// </summary> | 284 | /// </summary> |
285 | /// <param name="pbs"></param> | 285 | /// <param name="pbs"></param> |
286 | /// <returns></returns> | 286 | /// <returns></returns> |
287 | public bool needsMeshing(PrimitiveBaseShape pbs) | 287 | public bool needsMeshing(ODEPhysRepData repData) |
288 | { | 288 | { |
289 | PrimitiveBaseShape pbs = repData.pbs; | ||
289 | // check sculpts or meshs | 290 | // check sculpts or meshs |
290 | if (pbs.SculptEntry) | 291 | if (pbs.SculptEntry) |
291 | { | 292 | { |
@@ -301,6 +302,11 @@ namespace OpenSim.Region.PhysicsModule.ubOde | |||
301 | if (forceSimplePrimMeshing) | 302 | if (forceSimplePrimMeshing) |
302 | return true; | 303 | return true; |
303 | 304 | ||
305 | // convex shapes have no holes | ||
306 | ushort profilehollow = pbs.ProfileHollow; | ||
307 | if(repData.shapetype == 2) | ||
308 | profilehollow = 0; | ||
309 | |||
304 | // if it's a standard box or sphere with no cuts, hollows, twist or top shear, return false since ODE can use an internal representation for the prim | 310 | // if it's a standard box or sphere with no cuts, hollows, twist or top shear, return false since ODE can use an internal representation for the prim |
305 | 311 | ||
306 | if ((pbs.ProfileShape == ProfileShape.Square && pbs.PathCurve == (byte)Extrusion.Straight) | 312 | if ((pbs.ProfileShape == ProfileShape.Square && pbs.PathCurve == (byte)Extrusion.Straight) |
@@ -309,7 +315,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde | |||
309 | { | 315 | { |
310 | 316 | ||
311 | if (pbs.ProfileBegin == 0 && pbs.ProfileEnd == 0 | 317 | if (pbs.ProfileBegin == 0 && pbs.ProfileEnd == 0 |
312 | && pbs.ProfileHollow == 0 | 318 | && profilehollow == 0 |
313 | && pbs.PathTwist == 0 && pbs.PathTwistBegin == 0 | 319 | && pbs.PathTwist == 0 && pbs.PathTwistBegin == 0 |
314 | && pbs.PathBegin == 0 && pbs.PathEnd == 0 | 320 | && pbs.PathBegin == 0 && pbs.PathEnd == 0 |
315 | && pbs.PathTaperX == 0 && pbs.PathTaperY == 0 | 321 | && pbs.PathTaperX == 0 && pbs.PathTaperY == 0 |
@@ -326,7 +332,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde | |||
326 | 332 | ||
327 | int iPropertiesNotSupportedDefault = 0; | 333 | int iPropertiesNotSupportedDefault = 0; |
328 | 334 | ||
329 | if (pbs.ProfileHollow != 0) | 335 | if (profilehollow != 0) |
330 | iPropertiesNotSupportedDefault++; | 336 | iPropertiesNotSupportedDefault++; |
331 | 337 | ||
332 | if ((pbs.PathBegin != 0) || pbs.PathEnd != 0) | 338 | if ((pbs.PathBegin != 0) || pbs.PathEnd != 0) |
@@ -407,7 +413,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde | |||
407 | PhysicsActor actor = repData.actor; | 413 | PhysicsActor actor = repData.actor; |
408 | PrimitiveBaseShape pbs = repData.pbs; | 414 | PrimitiveBaseShape pbs = repData.pbs; |
409 | 415 | ||
410 | if (!needsMeshing(pbs)) | 416 | if (!needsMeshing(repData)) |
411 | { | 417 | { |
412 | repData.meshState = MeshState.noNeed; | 418 | repData.meshState = MeshState.noNeed; |
413 | repData.hasOBB = false; | 419 | repData.hasOBB = false; |
@@ -417,17 +423,17 @@ namespace OpenSim.Region.PhysicsModule.ubOde | |||
417 | IMesh mesh = null; | 423 | IMesh mesh = null; |
418 | 424 | ||
419 | Vector3 size = repData.size; | 425 | Vector3 size = repData.size; |
420 | byte shapetype = repData.shapetype; | ||
421 | |||
422 | bool convex; | ||
423 | 426 | ||
424 | int clod = (int)LevelOfDetail.High; | 427 | int clod = (int)LevelOfDetail.High; |
428 | bool convex; | ||
429 | byte shapetype = repData.shapetype; | ||
425 | if (shapetype == 0) | 430 | if (shapetype == 0) |
426 | convex = false; | 431 | convex = false; |
427 | else | 432 | else |
428 | { | 433 | { |
429 | convex = true; | 434 | convex = true; |
430 | if (pbs.SculptType != (byte)SculptType.Mesh) | 435 | // sculpts pseudo convex |
436 | if (pbs.SculptEntry && pbs.SculptType != (byte)SculptType.Mesh) | ||
431 | clod = (int)LevelOfDetail.Low; | 437 | clod = (int)LevelOfDetail.Low; |
432 | } | 438 | } |
433 | 439 | ||
@@ -483,7 +489,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde | |||
483 | repData.mesh = null; | 489 | repData.mesh = null; |
484 | repData.hasOBB = false; | 490 | repData.hasOBB = false; |
485 | 491 | ||
486 | if (!needsMeshing(pbs)) | 492 | if (!needsMeshing(repData)) |
487 | { | 493 | { |
488 | repData.meshState = MeshState.noNeed; | 494 | repData.meshState = MeshState.noNeed; |
489 | return; | 495 | return; |
diff --git a/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs b/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs index 2ae0881..7f0713a 100644 --- a/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs +++ b/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs | |||
@@ -349,7 +349,7 @@ namespace OpenSim.Region.PhysicsModule.ubODEMeshing | |||
349 | } | 349 | } |
350 | else | 350 | else |
351 | { | 351 | { |
352 | if (!GenerateCoordsAndFacesFromPrimShapeData(primName, primShape, lod, out coords, out faces)) | 352 | if (!GenerateCoordsAndFacesFromPrimShapeData(primName, primShape, lod, convex, out coords, out faces)) |
353 | return null; | 353 | return null; |
354 | } | 354 | } |
355 | 355 | ||
@@ -942,7 +942,8 @@ namespace OpenSim.Region.PhysicsModule.ubODEMeshing | |||
942 | /// <param name="faces">Faces are added to this list by the method.</param> | 942 | /// <param name="faces">Faces are added to this list by the method.</param> |
943 | /// <returns>true if coords and faces were successfully generated, false if not</returns> | 943 | /// <returns>true if coords and faces were successfully generated, false if not</returns> |
944 | private bool GenerateCoordsAndFacesFromPrimShapeData( | 944 | private bool GenerateCoordsAndFacesFromPrimShapeData( |
945 | string primName, PrimitiveBaseShape primShape, float lod, out List<Coord> coords, out List<Face> faces) | 945 | string primName, PrimitiveBaseShape primShape, float lod, bool convex, |
946 | out List<Coord> coords, out List<Face> faces) | ||
946 | { | 947 | { |
947 | PrimMesh primMesh; | 948 | PrimMesh primMesh; |
948 | coords = new List<Coord>(); | 949 | coords = new List<Coord>(); |
@@ -970,7 +971,9 @@ namespace OpenSim.Region.PhysicsModule.ubODEMeshing | |||
970 | profileBegin = profileEnd - 0.02f; | 971 | profileBegin = profileEnd - 0.02f; |
971 | 972 | ||
972 | float profileHollow = (float)primShape.ProfileHollow * 2.0e-5f; | 973 | float profileHollow = (float)primShape.ProfileHollow * 2.0e-5f; |
973 | if (profileHollow > 0.95f) | 974 | if(convex) |
975 | profileHollow = 0.0f; | ||
976 | else if (profileHollow > 0.95f) | ||
974 | profileHollow = 0.95f; | 977 | profileHollow = 0.95f; |
975 | 978 | ||
976 | int sides = 4; | 979 | int sides = 4; |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 71e8ca9..7efdc62 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -6307,6 +6307,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
6307 | { | 6307 | { |
6308 | return World.RegionInfo.ObjectCapacity.ToString(); | 6308 | return World.RegionInfo.ObjectCapacity.ToString(); |
6309 | } | 6309 | } |
6310 | else if (name == "region_object_bonus") | ||
6311 | { | ||
6312 | return World.RegionInfo.RegionSettings.ObjectBonus.ToString(); | ||
6313 | } | ||
6310 | else | 6314 | else |
6311 | { | 6315 | { |
6312 | return ""; | 6316 | return ""; |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index b101cf9..9742119 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | |||
@@ -3001,7 +3001,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3001 | 3001 | ||
3002 | public void osNpcSetProfileAbout(LSL_Key npc, string about) | 3002 | public void osNpcSetProfileAbout(LSL_Key npc, string about) |
3003 | { | 3003 | { |
3004 | CheckThreatLevel(ThreatLevel.High, "osNpcCreate"); | 3004 | CheckThreatLevel(ThreatLevel.Low, "osNpcSetProfileAbout"); |
3005 | m_host.AddScriptLPS(1); | 3005 | m_host.AddScriptLPS(1); |
3006 | 3006 | ||
3007 | INPCModule module = World.RequestModuleInterface<INPCModule>(); | 3007 | INPCModule module = World.RequestModuleInterface<INPCModule>(); |
@@ -3018,6 +3018,35 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3018 | } | 3018 | } |
3019 | } | 3019 | } |
3020 | 3020 | ||
3021 | public void osNpcSetProfileImage(LSL_Key npc, string image) | ||
3022 | { | ||
3023 | CheckThreatLevel(ThreatLevel.Low, "osNpcSetProfileImage"); | ||
3024 | m_host.AddScriptLPS(1); | ||
3025 | |||
3026 | INPCModule module = World.RequestModuleInterface<INPCModule>(); | ||
3027 | if (module != null) | ||
3028 | { | ||
3029 | UUID npcId = new UUID(npc.m_string); | ||
3030 | |||
3031 | if (!module.CheckPermissions(npcId, m_host.OwnerID)) | ||
3032 | return; | ||
3033 | |||
3034 | UUID ImageID = new UUID(); | ||
3035 | |||
3036 | ImageID = ScriptUtils.GetAssetIdFromItemName(m_host, image, (int)AssetType.Texture); | ||
3037 | |||
3038 | if (ImageID == null || ImageID == UUID.Zero) | ||
3039 | { | ||
3040 | if (!UUID.TryParse(image, out ImageID)) | ||
3041 | return; | ||
3042 | } | ||
3043 | |||
3044 | ScenePresence sp = World.GetScenePresence(npcId); | ||
3045 | if (sp != null) | ||
3046 | ((INPC)(sp.ControllingClient)).profileImage = ImageID; | ||
3047 | } | ||
3048 | } | ||
3049 | |||
3021 | public void osNpcSay(LSL_Key npc, string message) | 3050 | public void osNpcSay(LSL_Key npc, string message) |
3022 | { | 3051 | { |
3023 | osNpcSay(npc, 0, message); | 3052 | osNpcSay(npc, 0, message); |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Interface/IOSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Interface/IOSSL_Api.cs index 87b0967..cf3e6df 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Interface/IOSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Interface/IOSSL_Api.cs | |||
@@ -344,6 +344,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Interfaces | |||
344 | void osNpcSetRot(LSL_Key npc, rotation rot); | 344 | void osNpcSetRot(LSL_Key npc, rotation rot); |
345 | void osNpcStopMoveToTarget(LSL_Key npc); | 345 | void osNpcStopMoveToTarget(LSL_Key npc); |
346 | void osNpcSetProfileAbout(LSL_Key npc, string about); | 346 | void osNpcSetProfileAbout(LSL_Key npc, string about); |
347 | void osNpcSetProfileImage(LSL_Key npc, string image); | ||
347 | void osNpcSay(key npc, string message); | 348 | void osNpcSay(key npc, string message); |
348 | void osNpcSay(key npc, int channel, string message); | 349 | void osNpcSay(key npc, int channel, string message); |
349 | void osNpcShout(key npc, int channel, string message); | 350 | void osNpcShout(key npc, int channel, string message); |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/OSSL_Stub.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/OSSL_Stub.cs index 5bc998e..2e8a76c 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/OSSL_Stub.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/OSSL_Stub.cs | |||
@@ -642,6 +642,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase | |||
642 | m_OSSL_Functions.osNpcSetProfileAbout(npc, about); | 642 | m_OSSL_Functions.osNpcSetProfileAbout(npc, about); |
643 | } | 643 | } |
644 | 644 | ||
645 | public void osNpcSetProfileImage(LSL_Key npc, string image) | ||
646 | { | ||
647 | m_OSSL_Functions.osNpcSetProfileImage(npc, image); | ||
648 | } | ||
649 | |||
645 | public void osNpcSay(key npc, string message) | 650 | public void osNpcSay(key npc, string message) |
646 | { | 651 | { |
647 | m_OSSL_Functions.osNpcSay(npc, message); | 652 | m_OSSL_Functions.osNpcSay(npc, message); |
diff --git a/OpenSim/Server/Handlers/Hypergrid/HypergridHandlers.cs b/OpenSim/Server/Handlers/Hypergrid/HypergridHandlers.cs index 2d0b2b6..6bd24db 100644 --- a/OpenSim/Server/Handlers/Hypergrid/HypergridHandlers.cs +++ b/OpenSim/Server/Handlers/Hypergrid/HypergridHandlers.cs | |||
@@ -125,6 +125,7 @@ namespace OpenSim.Server.Handlers.Hypergrid | |||
125 | hash["hostname"] = regInfo.ExternalHostName; | 125 | hash["hostname"] = regInfo.ExternalHostName; |
126 | hash["http_port"] = regInfo.HttpPort.ToString(); | 126 | hash["http_port"] = regInfo.HttpPort.ToString(); |
127 | hash["internal_port"] = regInfo.InternalEndPoint.Port.ToString(); | 127 | hash["internal_port"] = regInfo.InternalEndPoint.Port.ToString(); |
128 | hash["server_uri"] = regInfo.ServerURI; | ||
128 | } | 129 | } |
129 | 130 | ||
130 | if (message != null) | 131 | if (message != null) |
diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianProfiles.cs b/OpenSim/Services/Connectors/SimianGrid/SimianProfiles.cs index 8fc766d..17f4fc6 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianProfiles.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianProfiles.cs | |||
@@ -308,11 +308,11 @@ namespace OpenSim.Services.Connectors.SimianGrid | |||
308 | about = new OSDMap(0); | 308 | about = new OSDMap(0); |
309 | 309 | ||
310 | // Check if this user is a grid operator | 310 | // Check if this user is a grid operator |
311 | byte[] charterMember; | 311 | byte[] membershipType; |
312 | if (user["AccessLevel"].AsInteger() >= 200) | 312 | if (user["AccessLevel"].AsInteger() >= 200) |
313 | charterMember = Utils.StringToBytes("Operator"); | 313 | membershipType = Utils.StringToBytes("Operator"); |
314 | else | 314 | else |
315 | charterMember = Utils.EmptyBytes; | 315 | membershipType = Utils.EmptyBytes; |
316 | 316 | ||
317 | // Check if the user is online | 317 | // Check if the user is online |
318 | if (client.Scene is Scene) | 318 | if (client.Scene is Scene) |
@@ -327,7 +327,7 @@ namespace OpenSim.Services.Connectors.SimianGrid | |||
327 | flags |= ProfileFlags.Identified; | 327 | flags |= ProfileFlags.Identified; |
328 | 328 | ||
329 | client.SendAvatarProperties(avatarID, about["About"].AsString(), user["CreationDate"].AsDate().ToString("M/d/yyyy", | 329 | client.SendAvatarProperties(avatarID, about["About"].AsString(), user["CreationDate"].AsDate().ToString("M/d/yyyy", |
330 | System.Globalization.CultureInfo.InvariantCulture), charterMember, about["FLAbout"].AsString(), (uint)flags, | 330 | System.Globalization.CultureInfo.InvariantCulture), membershipType, about["FLAbout"].AsString(), (uint)flags, |
331 | about["FLImage"].AsUUID(), about["Image"].AsUUID(), about["URL"].AsString(), user["Partner"].AsUUID()); | 331 | about["FLImage"].AsUUID(), about["Image"].AsUUID(), about["URL"].AsString(), user["Partner"].AsUUID()); |
332 | 332 | ||
333 | OSDMap interests = null; | 333 | OSDMap interests = null; |
diff --git a/OpenSim/Services/GridService/HypergridLinker.cs b/OpenSim/Services/GridService/HypergridLinker.cs index e00025b..ceb2c6e 100644 --- a/OpenSim/Services/GridService/HypergridLinker.cs +++ b/OpenSim/Services/GridService/HypergridLinker.cs | |||
@@ -255,11 +255,8 @@ namespace OpenSim.Services.GridService | |||
255 | regionName = parts[2]; | 255 | regionName = parts[2]; |
256 | } | 256 | } |
257 | 257 | ||
258 | if(port == 80) | 258 | serverURI = "http://"+ host +":"+ port.ToString() + "/"; |
259 | serverURI = "http://"+ host + "/"; | 259 | } |
260 | else | ||
261 | serverURI = "http://"+ host +":"+ port.ToString() + "/"; | ||
262 | } | ||
263 | } | 260 | } |
264 | else | 261 | else |
265 | { | 262 | { |
@@ -301,6 +298,10 @@ namespace OpenSim.Services.GridService | |||
301 | if(!string.IsNullOrEmpty(regionName)) | 298 | if(!string.IsNullOrEmpty(regionName)) |
302 | regionName = regionName.Trim(new char[] { '"', ' ' }); | 299 | regionName = regionName.Trim(new char[] { '"', ' ' }); |
303 | serverURI = uri.AbsoluteUri; | 300 | serverURI = uri.AbsoluteUri; |
301 | if(uri.Port == 80) | ||
302 | serverURI = serverURI.Trim(new char[] { '/', ' ' }) +":80/"; | ||
303 | else if(uri.Port == 443) | ||
304 | serverURI = serverURI.Trim(new char[] { '/', ' ' }) +":443/"; | ||
304 | return true; | 305 | return true; |
305 | } | 306 | } |
306 | 307 | ||
diff --git a/OpenSim/Tests/Common/Helpers/ClientStackHelpers.cs b/OpenSim/Tests/Common/Helpers/ClientStackHelpers.cs index 33cd8a2..df9f6f2 100644 --- a/OpenSim/Tests/Common/Helpers/ClientStackHelpers.cs +++ b/OpenSim/Tests/Common/Helpers/ClientStackHelpers.cs | |||
@@ -86,10 +86,10 @@ namespace OpenSim.Tests.Common | |||
86 | uint port = 0; | 86 | uint port = 0; |
87 | AgentCircuitManager acm = scene.AuthenticateHandler; | 87 | AgentCircuitManager acm = scene.AuthenticateHandler; |
88 | 88 | ||
89 | TestLLUDPServer udpServer = new TestLLUDPServer(IPAddress.Any, ref port, 0, false, configSource, acm); | 89 | TestLLUDPServer udpServer = new TestLLUDPServer(IPAddress.Any, ref port, 0, configSource, acm); |
90 | udpServer.AddScene(scene); | 90 | udpServer.AddScene(scene); |
91 | 91 | ||
92 | return udpServer; | 92 | return udpServer; |
93 | } | 93 | } |
94 | } | 94 | } |
95 | } \ No newline at end of file | 95 | } |
diff --git a/OpenSim/Tests/Common/Mock/TestClient.cs b/OpenSim/Tests/Common/Mock/TestClient.cs index 9251c4f..f407e5a 100644 --- a/OpenSim/Tests/Common/Mock/TestClient.cs +++ b/OpenSim/Tests/Common/Mock/TestClient.cs | |||
@@ -990,7 +990,7 @@ namespace OpenSim.Tests.Common | |||
990 | { | 990 | { |
991 | } | 991 | } |
992 | 992 | ||
993 | public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] charterMember, | 993 | public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] membershipType, |
994 | string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, | 994 | string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, |
995 | UUID partnerID) | 995 | UUID partnerID) |
996 | { | 996 | { |
diff --git a/OpenSim/Tests/Common/Mock/TestLLUDPServer.cs b/OpenSim/Tests/Common/Mock/TestLLUDPServer.cs index 26887c9..b2c6a8c 100644 --- a/OpenSim/Tests/Common/Mock/TestLLUDPServer.cs +++ b/OpenSim/Tests/Common/Mock/TestLLUDPServer.cs | |||
@@ -43,8 +43,8 @@ namespace OpenSim.Tests.Common | |||
43 | { | 43 | { |
44 | public List<Packet> PacketsSent { get; private set; } | 44 | public List<Packet> PacketsSent { get; private set; } |
45 | 45 | ||
46 | public TestLLUDPServer(IPAddress listenIP, ref uint port, int proxyPortOffsetParm, bool allow_alternate_port, IConfigSource configSource, AgentCircuitManager circuitManager) | 46 | public TestLLUDPServer(IPAddress listenIP, ref uint port, int proxyPortOffsetParm, IConfigSource configSource, AgentCircuitManager circuitManager) |
47 | : base(listenIP, ref port, proxyPortOffsetParm, allow_alternate_port, configSource, circuitManager) | 47 | : base(listenIP, ref port, proxyPortOffsetParm, configSource, circuitManager) |
48 | { | 48 | { |
49 | PacketsSent = new List<Packet>(); | 49 | PacketsSent = new List<Packet>(); |
50 | } | 50 | } |