From 77de28965ae5fc6de3c60a28ce7d4e59643a2a70 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Mon, 16 Aug 2010 11:33:59 -0700 Subject: Work on TeleportStart: renamed method from TeleportLocationStart to TeleportStart, and now sending this upon all teleports, not just some, and in the right place (EntityTransferModule). --- OpenSim/Client/MXP/ClientStack/MXPClientView.cs | 2 +- .../Client/Sirikata/ClientStack/SirikataClientView.cs | 2 +- OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs | 2 +- OpenSim/Framework/IClientAPI.cs | 2 +- OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | 19 +++++++++++++++---- .../Framework/EntityTransfer/EntityTransferModule.cs | 10 ++++------ .../World/Estate/EstateManagementModule.cs | 3 --- .../Region/Examples/SimpleModule/MyNpcCharacter.cs | 2 +- .../InternetRelayClientView/Server/IRCClientView.cs | 2 +- OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | 2 +- .../ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 1 - .../Shared/Api/Implementation/OSSL_Api.cs | 2 -- OpenSim/Tests/Common/Mock/TestClient.cs | 2 +- 13 files changed, 27 insertions(+), 24 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Client/MXP/ClientStack/MXPClientView.cs b/OpenSim/Client/MXP/ClientStack/MXPClientView.cs index 65921a2..5e16347 100644 --- a/OpenSim/Client/MXP/ClientStack/MXPClientView.cs +++ b/OpenSim/Client/MXP/ClientStack/MXPClientView.cs @@ -1015,7 +1015,7 @@ namespace OpenSim.Client.MXP.ClientStack // Need to translate to MXP somehow } - public void SendTeleportLocationStart() + public void SendTeleportStart(uint flags) { // Need to translate to MXP somehow } diff --git a/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs b/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs index b808e95..1c702d2 100644 --- a/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs +++ b/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs @@ -573,7 +573,7 @@ namespace OpenSim.Client.Sirikata.ClientStack throw new System.NotImplementedException(); } - public void SendTeleportLocationStart() + public void SendTeleportStart(uint flags) { throw new System.NotImplementedException(); } diff --git a/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs b/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs index a6c490b..e954aa3 100644 --- a/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs +++ b/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs @@ -579,7 +579,7 @@ namespace OpenSim.Client.VWoHTTP.ClientStack throw new System.NotImplementedException(); } - public void SendTeleportLocationStart() + public void SendTeleportStart(uint flags) { throw new System.NotImplementedException(); } diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index db74548..81f99b0 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs @@ -1011,7 +1011,7 @@ namespace OpenSim.Framework uint flags, string capsURL); void SendTeleportFailed(string reason); - void SendTeleportLocationStart(); + void SendTeleportStart(uint flags); void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance); void SendPayPrice(UUID objectID, int[] payPrice); diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs index c11b9a2..bb9e6d4 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs @@ -1432,16 +1432,27 @@ namespace OpenSim.Region.ClientStack.LindenUDP /// /// /// - public void SendTeleportLocationStart() + public void SendTeleportStart(uint flags) { - //TeleportStartPacket tpStart = (TeleportStartPacket)PacketPool.Instance.GetPacket(PacketType.TeleportStart); - TeleportStartPacket tpStart = new TeleportStartPacket(); - tpStart.Info.TeleportFlags = 16; // Teleport via location + TeleportStartPacket tpStart = (TeleportStartPacket)PacketPool.Instance.GetPacket(PacketType.TeleportStart); + //TeleportStartPacket tpStart = new TeleportStartPacket(); + tpStart.Info.TeleportFlags = flags; //16; // Teleport via location // Hack to get this out immediately and skip throttles OutPacket(tpStart, ThrottleOutPacketType.Unknown); } + public void SendTeleportProgress(uint flags, string message) + { + TeleportProgressPacket tpProgress = (TeleportProgressPacket)PacketPool.Instance.GetPacket(PacketType.TeleportProgress); + tpProgress.AgentData.AgentID = this.AgentId; + tpProgress.Info.TeleportFlags = flags; + tpProgress.Info.Message = Util.StringToBytes256(message); + + // Hack to get this out immediately and skip throttles + OutPacket(tpProgress, ThrottleOutPacketType.Unknown); + } + public void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) { MoneyBalanceReplyPacket money = (MoneyBalanceReplyPacket)PacketPool.Instance.GetPacket(PacketType.MoneyBalanceReply); diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs index 607219e..751d49a 100644 --- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs +++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs @@ -174,9 +174,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer position.Z = newPosZ; } - // Only send this if the event queue is null - if (eq == null) - sp.ControllingClient.SendTeleportLocationStart(); + sp.ControllingClient.SendTeleportStart(teleportFlags); sp.ControllingClient.SendLocalTeleport(position, lookAt, teleportFlags); sp.Teleport(position); @@ -257,9 +255,6 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer ulong destinationHandle = finalDestination.RegionHandle; - if (eq == null) - sp.ControllingClient.SendTeleportLocationStart(); - // Let's do DNS resolution only once in this process, please! // This may be a costly operation. The reg.ExternalEndPoint field is not a passive field, // it's actually doing a lot of work. @@ -277,6 +272,8 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer return; } + sp.ControllingClient.SendTeleportStart(teleportFlags); + // the avatar.Close below will clear the child region list. We need this below for (possibly) // closing the child agents, so save it here (we need a copy as it is Clear()-ed). //List childRegions = new List(avatar.GetKnownRegionList()); @@ -320,6 +317,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer if (NeedsNewAgent(oldRegionX, newRegionX, oldRegionY, newRegionY)) { + #region IP Translation for NAT IClientIPEndpoint ipepClient; if (sp.ClientView.TryGet(out ipepClient)) diff --git a/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs b/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs index 940b535..51f2c41 100644 --- a/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs +++ b/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs @@ -343,7 +343,6 @@ namespace OpenSim.Region.CoreModules.World.Estate { if (!s.IsChildAgent) { - s.ControllingClient.SendTeleportLocationStart(); m_scene.TeleportClientHome(user, s.ControllingClient); } } @@ -478,7 +477,6 @@ namespace OpenSim.Region.CoreModules.World.Estate ScenePresence s = m_scene.GetScenePresence(prey); if (s != null) { - s.ControllingClient.SendTeleportLocationStart(); m_scene.TeleportClientHome(prey, s.ControllingClient); } } @@ -498,7 +496,6 @@ namespace OpenSim.Region.CoreModules.World.Estate // Also make sure they are actually in the region if (p != null && !p.IsChildAgent) { - p.ControllingClient.SendTeleportLocationStart(); m_scene.TeleportClientHome(p.UUID, p.ControllingClient); } } diff --git a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs index f6e6163..3f5aa46 100644 --- a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs +++ b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs @@ -520,7 +520,7 @@ namespace OpenSim.Region.Examples.SimpleModule { } - public virtual void SendTeleportLocationStart() + public virtual void SendTeleportStart(uint flags) { } diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs index ee7aa2da..19bb002 100644 --- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs +++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs @@ -1035,7 +1035,7 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server } - public void SendTeleportLocationStart() + public void SendTeleportStart(uint flags) { } diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs index 2e0450c..944bac6 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs @@ -611,7 +611,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC { } - public virtual void SendTeleportLocationStart() + public virtual void SendTeleportStart(uint flags) { } diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 32e46ec..b21e532 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs @@ -4070,7 +4070,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api if (m_host.OwnerID == World.LandChannel.GetLandObject( presence.AbsolutePosition.X, presence.AbsolutePosition.Y).LandData.OwnerID) { - presence.ControllingClient.SendTeleportLocationStart(); World.TeleportClientHome(agentId, presence.ControllingClient); } } diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index 01b64eb..a529a94 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs @@ -664,7 +664,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api regionName = regInfo.RegionName; } } - presence.ControllingClient.SendTeleportLocationStart(); World.RequestTeleportLocation(presence.ControllingClient, regionName, new Vector3((float)position.x, (float)position.y, (float)position.z), new Vector3((float)lookat.x, (float)lookat.y, (float)lookat.z), (uint)TPFlags.ViaLocation); @@ -696,7 +695,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api == World.LandChannel.GetLandObject( presence.AbsolutePosition.X, presence.AbsolutePosition.Y).LandData.OwnerID) { - presence.ControllingClient.SendTeleportLocationStart(); World.RequestTeleportLocation(presence.ControllingClient, regionHandle, new Vector3((float)position.x, (float)position.y, (float)position.z), new Vector3((float)lookat.x, (float)lookat.y, (float)lookat.z), (uint)TPFlags.ViaLocation); diff --git a/OpenSim/Tests/Common/Mock/TestClient.cs b/OpenSim/Tests/Common/Mock/TestClient.cs index 999cf5e..0dee374 100644 --- a/OpenSim/Tests/Common/Mock/TestClient.cs +++ b/OpenSim/Tests/Common/Mock/TestClient.cs @@ -614,7 +614,7 @@ namespace OpenSim.Tests.Common.Mock { } - public virtual void SendTeleportLocationStart() + public virtual void SendTeleportStart(uint flags) { } -- cgit v1.1 From a8b80ef800e78d9fa321bc2388b4d8336f454b1d Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Mon, 16 Aug 2010 11:39:46 -0700 Subject: Added SendTeleportProgress to IClientAPI. Ya know what that means... 8 files affected. --- OpenSim/Client/MXP/ClientStack/MXPClientView.cs | 4 ++++ OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs | 5 +++++ OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs | 5 +++++ OpenSim/Framework/IClientAPI.cs | 2 ++ OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs | 4 ++++ .../Agent/InternetRelayClientView/Server/IRCClientView.cs | 4 ++++ OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | 4 ++++ OpenSim/Tests/Common/Mock/TestClient.cs | 4 ++++ 8 files changed, 32 insertions(+) (limited to 'OpenSim') diff --git a/OpenSim/Client/MXP/ClientStack/MXPClientView.cs b/OpenSim/Client/MXP/ClientStack/MXPClientView.cs index 5e16347..b5b2508 100644 --- a/OpenSim/Client/MXP/ClientStack/MXPClientView.cs +++ b/OpenSim/Client/MXP/ClientStack/MXPClientView.cs @@ -1020,6 +1020,10 @@ namespace OpenSim.Client.MXP.ClientStack // Need to translate to MXP somehow } + public void SendTeleportProgress(uint flags, string message) + { + } + public void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) { // Need to translate to MXP somehow diff --git a/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs b/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs index 1c702d2..c1e281a 100644 --- a/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs +++ b/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs @@ -578,6 +578,11 @@ namespace OpenSim.Client.Sirikata.ClientStack throw new System.NotImplementedException(); } + public void SendTeleportProgress(uint flags, string message) + { + throw new System.NotImplementedException(); + } + public void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) { throw new System.NotImplementedException(); diff --git a/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs b/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs index e954aa3..99a46dc 100644 --- a/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs +++ b/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs @@ -584,6 +584,11 @@ namespace OpenSim.Client.VWoHTTP.ClientStack throw new System.NotImplementedException(); } + public void SendTeleportProgress(uint flags, string message) + { + throw new System.NotImplementedException(); + } + public void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) { throw new System.NotImplementedException(); diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index 81f99b0..94815cd 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs @@ -1012,6 +1012,8 @@ namespace OpenSim.Framework void SendTeleportFailed(string reason); void SendTeleportStart(uint flags); + void SendTeleportProgress(uint flags, string message); + void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance); void SendPayPrice(UUID objectID, int[] payPrice); diff --git a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs index 3f5aa46..268612e 100644 --- a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs +++ b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs @@ -524,6 +524,10 @@ namespace OpenSim.Region.Examples.SimpleModule { } + public virtual void SendTeleportProgress(uint flags, string message) + { + } + public virtual void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) { } diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs index 19bb002..6793ef6 100644 --- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs +++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs @@ -1040,6 +1040,10 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server } + public void SendTeleportProgress(uint flags, string message) + { + } + public void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) { diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs index 944bac6..fae12b6 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs @@ -615,6 +615,10 @@ namespace OpenSim.Region.OptionalModules.World.NPC { } + public virtual void SendTeleportProgress(uint flags, string message) + { + } + public virtual void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) { } diff --git a/OpenSim/Tests/Common/Mock/TestClient.cs b/OpenSim/Tests/Common/Mock/TestClient.cs index 0dee374..e46f9b7 100644 --- a/OpenSim/Tests/Common/Mock/TestClient.cs +++ b/OpenSim/Tests/Common/Mock/TestClient.cs @@ -618,6 +618,10 @@ namespace OpenSim.Tests.Common.Mock { } + public void SendTeleportProgress(uint flags, string message) + { + } + public virtual void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) { } -- cgit v1.1 From 69ad04cdf6ca899877a38fd4f9248f4107e3a7ce Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Mon, 16 Aug 2010 12:03:13 -0700 Subject: Attempt at sending TeleportProgress, but it doesn't seem to be doing anything at all. Left it commented, just as a reminder for where those messages could be sent. --- .../CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'OpenSim') diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs index 751d49a..bb98dba 100644 --- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs +++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs @@ -317,6 +317,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer if (NeedsNewAgent(oldRegionX, newRegionX, oldRegionY, newRegionY)) { + //sp.ControllingClient.SendTeleportProgress(teleportFlags, "Creating agent..."); #region IP Translation for NAT IClientIPEndpoint ipepClient; @@ -395,6 +396,8 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer agent.Position = position; SetCallbackURL(agent, sp.Scene.RegionInfo); + //sp.ControllingClient.SendTeleportProgress(teleportFlags, "Updating agent..."); + if (!UpdateAgent(reg, finalDestination, agent)) { // Region doesn't take it -- cgit v1.1 From d7824b86d97bf3b219b67c8908eb28ba0f3edbeb Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Mon, 16 Aug 2010 14:36:20 -0700 Subject: Fixes mantis #4954 for the xml-rpc calls of the UserAgentServiceConnector. Basically, let's not let the xml-rpc library do the DNS conversion... --- .../Connectors/Hypergrid/UserAgentServiceConnector.cs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs b/OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs index 96d2605..69dff3c 100644 --- a/OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs +++ b/OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs @@ -53,9 +53,20 @@ namespace OpenSim.Services.Connectors.Hypergrid MethodBase.GetCurrentMethod().DeclaringType); string m_ServerURL; + Uri m_Uri; public UserAgentServiceConnector(string url) { m_ServerURL = url; + try + { + m_Uri = new Uri(m_ServerURL); + IPAddress ip = Util.GetHostFromDNS(m_Uri.Host); + m_ServerURL = "http://" + ip.ToString() + ":" + m_Uri.Port; + } + catch (Exception e) + { + m_log.DebugFormat("[USER AGENT CONNECTOR]: Malformed Uri {0}: {1}", m_ServerURL, e.Message); + } } public UserAgentServiceConnector(IConfigSource config) @@ -373,7 +384,7 @@ namespace OpenSim.Services.Connectors.Hypergrid if (response.IsFault) { - m_log.ErrorFormat("[HGrid]: remote call to {0} returned an error: {1}", m_ServerURL, response.FaultString); + m_log.ErrorFormat("[USER AGENT CONNECTOR]: remote call to {0} returned an error: {1}", m_ServerURL, response.FaultString); reason = "XMLRPC Fault"; return false; } @@ -403,7 +414,7 @@ namespace OpenSim.Services.Connectors.Hypergrid } catch (Exception e) { - m_log.ErrorFormat("[HGrid]: Got exception on GetBoolResponse response."); + m_log.ErrorFormat("[USER AGENT CONNECTOR]: Got exception on GetBoolResponse response."); if (hash.ContainsKey("result") && hash["result"] != null) m_log.ErrorFormat("Reply was ", (string)hash["result"]); reason = "Exception: " + e.Message; -- cgit v1.1 From a8c0b131f9aa62d4b6260fd37f89014e55b457cf Mon Sep 17 00:00:00 2001 From: John Hurliman Date: Tue, 17 Aug 2010 13:50:04 -0700 Subject: * Changed a few OSD.FromBinary() calls to the more accurate OSD.FromULong() to fix the build --- OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | 2 +- OpenSim/Region/CoreModules/Framework/EventQueue/EventQueueHelper.cs | 2 +- OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs index bb9e6d4..1d3bdf3 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs @@ -3033,7 +3033,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP { OSDMap GroupDataMap = new OSDMap(6); OSDMap NewGroupDataMap = new OSDMap(1); - GroupDataMap.Add("GroupPowers", OSD.FromBinary(m.GroupPowers)); + GroupDataMap.Add("GroupPowers", OSD.FromULong(m.GroupPowers)); GroupDataMap.Add("AcceptNotices", OSD.FromBoolean(m.AcceptNotices)); GroupDataMap.Add("GroupTitle", OSD.FromString(m.GroupTitle)); GroupDataMap.Add("GroupID", OSD.FromUUID(m.GroupID)); diff --git a/OpenSim/Region/CoreModules/Framework/EventQueue/EventQueueHelper.cs b/OpenSim/Region/CoreModules/Framework/EventQueue/EventQueueHelper.cs index 53a2a7d..e9bcae3 100644 --- a/OpenSim/Region/CoreModules/Framework/EventQueue/EventQueueHelper.cs +++ b/OpenSim/Region/CoreModules/Framework/EventQueue/EventQueueHelper.cs @@ -158,7 +158,7 @@ namespace OpenSim.Region.CoreModules.Framework.EventQueue info.Add("SimAccess", OSD.FromInteger(simAccess)); info.Add("SimIP", OSD.FromBinary(regionExternalEndPoint.Address.GetAddressBytes())); info.Add("SimPort", OSD.FromInteger(regionExternalEndPoint.Port)); - info.Add("TeleportFlags", OSD.FromBinary(1L << 4)); // AgentManager.TeleportFlags.ViaLocation + info.Add("TeleportFlags", OSD.FromULong(1L << 4)); // AgentManager.TeleportFlags.ViaLocation OSDArray infoArr = new OSDArray(); infoArr.Add(info); diff --git a/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs b/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs index 3f15b69..2969503 100644 --- a/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs +++ b/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs @@ -1129,7 +1129,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups OSDMap NewGroupDataMap = new OSDMap(1); GroupDataMap.Add("GroupID", OSD.FromUUID(membership.GroupID)); - GroupDataMap.Add("GroupPowers", OSD.FromBinary(membership.GroupPowers)); + GroupDataMap.Add("GroupPowers", OSD.FromULong(membership.GroupPowers)); GroupDataMap.Add("AcceptNotices", OSD.FromBoolean(membership.AcceptNotices)); GroupDataMap.Add("GroupInsigniaID", OSD.FromUUID(membership.GroupPicture)); GroupDataMap.Add("Contribution", OSD.FromInteger(membership.Contribution)); -- cgit v1.1 From 6ddf124c8af73d52132c3cc1047d01ac4cbcbadf Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Wed, 18 Aug 2010 20:17:20 +0200 Subject: Prevent a bad cast in llCreateLink(). --- OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'OpenSim') diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index b21e532..d38fe9f 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs @@ -3505,6 +3505,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api { m_host.AddScriptLPS(1); UUID invItemID = InventorySelf(); + UUID targetID; + + if (!UUID.TryParse(target, out targetID)) + return; TaskInventoryItem item; lock (m_host.TaskInventory) @@ -3524,7 +3528,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api if (sp != null) client = sp.ControllingClient; - SceneObjectPart targetPart = World.GetSceneObjectPart((UUID)target); + SceneObjectPart targetPart = World.GetSceneObjectPart((UUID)targetID); if (targetPart.ParentGroup.RootPart.AttachmentPoint != 0) return; // Fail silently if attached -- cgit v1.1