From 048939fbb5f13b283f9b4161bb7b2fefe808277c Mon Sep 17 00:00:00 2001 From: Sean Dague Date: Wed, 31 Oct 2007 14:08:12 +0000 Subject: fix typo in filename --- OpenSim/Framework/AgentCircuitData.cs | 52 +++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 OpenSim/Framework/AgentCircuitData.cs (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs new file mode 100644 index 0000000..3f17ca8 --- /dev/null +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -0,0 +1,52 @@ +/* +* Copyright (c) Contributors, http://opensimulator.org/ +* See CONTRIBUTORS.TXT for a full list of copyright holders. +* +* Redistribution and use in source and binary forms, with or without +* modification, are permitted provided that the following conditions are met: +* * Redistributions of source code must retain the above copyright +* notice, this list of conditions and the following disclaimer. +* * Redistributions in binary form must reproduce the above copyright +* notice, this list of conditions and the following disclaimer in the +* documentation and/or other materials provided with the distribution. +* * Neither the name of the OpenSim Project nor the +* names of its contributors may be used to endorse or promote products +* derived from this software without specific prior written permission. +* +* THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS AND ANY +* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +* DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY +* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +* +*/ +using System; +using libsecondlife; + +namespace OpenSim.Framework +{ + [Serializable] + public class AgentCircuitData + { + public AgentCircuitData() + { + } + + public LLUUID AgentID; + public LLUUID SessionID; + public LLUUID SecureSessionID; + public LLVector3 startpos; + public string firstname; + public string lastname; + public uint circuitcode; + public bool child; + public LLUUID InventoryFolder; + public LLUUID BaseFolder; + public string CapsPath = ""; + } +} \ No newline at end of file -- cgit v1.1 From cbc8a27b341a6b85ddf143d5ed381f3db3d9620b Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Fri, 7 Dec 2007 15:56:16 +0000 Subject: * Added class sAgentCircuitData and unmarked AgentCircuitData as Serializable. * Created converter constructors between sAgentCircuitData and AgentCircuitData --- OpenSim/Framework/AgentCircuitData.cs | 51 ++++++++++++++++++++++++++++++++++- 1 file changed, 50 insertions(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 3f17ca8..2c3a8ba 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -30,12 +30,25 @@ using libsecondlife; namespace OpenSim.Framework { - [Serializable] public class AgentCircuitData { public AgentCircuitData() { } + public AgentCircuitData(sAgentCircuitData cAgent) + { + AgentID = new LLUUID(cAgent.AgentID); + SessionID = new LLUUID(cAgent.SessionID); + SecureSessionID = new LLUUID(cAgent.SecureSessionID); + startpos = cAgent.startpos; + firstname = cAgent.firstname; + lastname = cAgent.lastname; + circuitcode = cAgent.circuitcode; + child = cAgent.child; + InventoryFolder = new LLUUID(cAgent.InventoryFolder); + BaseFolder = new LLUUID(cAgent.BaseFolder); + CapsPath = cAgent.CapsPath; + } public LLUUID AgentID; public LLUUID SessionID; @@ -49,4 +62,40 @@ namespace OpenSim.Framework public LLUUID BaseFolder; public string CapsPath = ""; } + + [Serializable] + public class sAgentCircuitData + { + public sAgentCircuitData() + { + } + public sAgentCircuitData(AgentCircuitData cAgent) + { + AgentID = cAgent.AgentID.UUID; + SessionID = cAgent.SessionID.UUID; + SecureSessionID = cAgent.SecureSessionID.UUID; + startpos = cAgent.startpos; + firstname = cAgent.firstname; + lastname = cAgent.lastname; + circuitcode = cAgent.circuitcode; + child = cAgent.child; + InventoryFolder = cAgent.InventoryFolder.UUID; + BaseFolder = cAgent.BaseFolder.UUID; + CapsPath = cAgent.CapsPath; + } + public Guid AgentID; + public Guid SessionID; + public Guid SecureSessionID; + public LLVector3 startpos; + public string firstname; + public string lastname; + public uint circuitcode; + public bool child; + public Guid InventoryFolder; + public Guid BaseFolder; + public string CapsPath = ""; + + + + } } \ No newline at end of file -- cgit v1.1 From 25ec01311d5c2b96f5ba5e5f1718166009912d18 Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Fri, 7 Dec 2007 18:20:34 +0000 Subject: * Serialized data properly for the InterRegionSingleton InformRegionChild method * This isn't really that big of a deal(worth lots of commits) doing this, however I'm doing it in small chunks because I'm multi-tasking. --- OpenSim/Framework/AgentCircuitData.cs | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 2c3a8ba..ddaaaf9 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -40,7 +40,7 @@ namespace OpenSim.Framework AgentID = new LLUUID(cAgent.AgentID); SessionID = new LLUUID(cAgent.SessionID); SecureSessionID = new LLUUID(cAgent.SecureSessionID); - startpos = cAgent.startpos; + startpos = new LLVector3(cAgent.startposx,cAgent.startposy,cAgent.startposz); firstname = cAgent.firstname; lastname = cAgent.lastname; circuitcode = cAgent.circuitcode; @@ -74,7 +74,9 @@ namespace OpenSim.Framework AgentID = cAgent.AgentID.UUID; SessionID = cAgent.SessionID.UUID; SecureSessionID = cAgent.SecureSessionID.UUID; - startpos = cAgent.startpos; + startposx = cAgent.startpos.X; + startposy = cAgent.startpos.Y; + startposz = cAgent.startpos.Z; firstname = cAgent.firstname; lastname = cAgent.lastname; circuitcode = cAgent.circuitcode; @@ -86,7 +88,9 @@ namespace OpenSim.Framework public Guid AgentID; public Guid SessionID; public Guid SecureSessionID; - public LLVector3 startpos; + public float startposx; + public float startposy; + public float startposz; public string firstname; public string lastname; public uint circuitcode; -- cgit v1.1 From af6eb67999875f12270ef19ed33c179556696754 Mon Sep 17 00:00:00 2001 From: Jeff Ames Date: Mon, 10 Dec 2007 05:25:16 +0000 Subject: saved OpenSim source code from the giant rampaging unterminated copyright notice of doom --- OpenSim/Framework/AgentCircuitData.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index ddaaaf9..0617a76 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -13,7 +13,7 @@ * names of its contributors may be used to endorse or promote products * derived from this software without specific prior written permission. * -* THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS AND ANY +* THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY @@ -102,4 +102,4 @@ namespace OpenSim.Framework } -} \ No newline at end of file +} -- cgit v1.1 From efd90b56b761219af6425b1c7a2cdd3b6ffb4de2 Mon Sep 17 00:00:00 2001 From: lbsa71 Date: Thu, 27 Dec 2007 21:41:48 +0000 Subject: * Optimized usings * shortened references * Removed redundant 'this' * Normalized EOF --- OpenSim/Framework/AgentCircuitData.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 0617a76..65a072f 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -35,12 +35,13 @@ namespace OpenSim.Framework public AgentCircuitData() { } + public AgentCircuitData(sAgentCircuitData cAgent) { AgentID = new LLUUID(cAgent.AgentID); SessionID = new LLUUID(cAgent.SessionID); SecureSessionID = new LLUUID(cAgent.SecureSessionID); - startpos = new LLVector3(cAgent.startposx,cAgent.startposy,cAgent.startposz); + startpos = new LLVector3(cAgent.startposx, cAgent.startposy, cAgent.startposz); firstname = cAgent.firstname; lastname = cAgent.lastname; circuitcode = cAgent.circuitcode; @@ -69,6 +70,7 @@ namespace OpenSim.Framework public sAgentCircuitData() { } + public sAgentCircuitData(AgentCircuitData cAgent) { AgentID = cAgent.AgentID.UUID; @@ -85,6 +87,7 @@ namespace OpenSim.Framework BaseFolder = cAgent.BaseFolder.UUID; CapsPath = cAgent.CapsPath; } + public Guid AgentID; public Guid SessionID; public Guid SecureSessionID; @@ -98,8 +101,5 @@ namespace OpenSim.Framework public Guid InventoryFolder; public Guid BaseFolder; public string CapsPath = ""; - - - } -} +} \ No newline at end of file -- cgit v1.1 From b25f9f322cdbcde7fd8c043137bf07992e5ef318 Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Tue, 15 Jan 2008 02:09:55 +0000 Subject: * Mother of all commits: * Cleaned up copyright notices in AssemblyInfo.cs's * Added Copyright headers to a bunch of files missing them * Replaced several common string instances with a static constant to prevent reallocation of the same strings thousands of times. "" -> String.Empty is the first such candidate. --- OpenSim/Framework/AgentCircuitData.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 65a072f..43ade36 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -61,7 +61,7 @@ namespace OpenSim.Framework public bool child; public LLUUID InventoryFolder; public LLUUID BaseFolder; - public string CapsPath = ""; + public string CapsPath = String.Empty; } [Serializable] @@ -100,6 +100,6 @@ namespace OpenSim.Framework public bool child; public Guid InventoryFolder; public Guid BaseFolder; - public string CapsPath = ""; + public string CapsPath = String.Empty; } } \ No newline at end of file -- cgit v1.1 From 7d40a0afb8fd3bd42f80ffded52d1a19256d5145 Mon Sep 17 00:00:00 2001 From: lbsa71 Date: Mon, 3 Mar 2008 08:15:14 +0000 Subject: * Changed the license headers. The Data Framework is now all OpenSim. Yay! *toots* --- OpenSim/Framework/AgentCircuitData.cs | 1 + 1 file changed, 1 insertion(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 43ade36..3ecc8a4 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -25,6 +25,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * */ + using System; using libsecondlife; -- cgit v1.1 From 47180080f0f4b93c60232b47ca4e093bd7c73a1d Mon Sep 17 00:00:00 2001 From: Jeff Ames Date: Tue, 18 Mar 2008 05:16:43 +0000 Subject: Formatting cleanup. --- OpenSim/Framework/AgentCircuitData.cs | 51 +++++++++++++++++------------------ 1 file changed, 25 insertions(+), 26 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 3ecc8a4..a8cbaf0 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -1,30 +1,29 @@ /* -* Copyright (c) Contributors, http://opensimulator.org/ -* See CONTRIBUTORS.TXT for a full list of copyright holders. -* -* Redistribution and use in source and binary forms, with or without -* modification, are permitted provided that the following conditions are met: -* * Redistributions of source code must retain the above copyright -* notice, this list of conditions and the following disclaimer. -* * Redistributions in binary form must reproduce the above copyright -* notice, this list of conditions and the following disclaimer in the -* documentation and/or other materials provided with the distribution. -* * Neither the name of the OpenSim Project nor the -* names of its contributors may be used to endorse or promote products -* derived from this software without specific prior written permission. -* -* THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY -* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -* DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY -* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND -* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -*/ + * Copyright (c) Contributors, http://opensimulator.org/ + * See CONTRIBUTORS.TXT for a full list of copyright holders. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * * Neither the name of the OpenSim Project nor the + * names of its contributors may be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ using System; using libsecondlife; -- cgit v1.1 From 375163a6fece8b3a57c7555246abe8338223a599 Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Tue, 29 Apr 2008 14:04:55 +0000 Subject: * Spring cleaning. * Added new generic "Location" class to handle 2D integer locations. Going to use it to replace all RegionHandle and X,Y coordinate references throughout the entire project. You have been warned. --- OpenSim/Framework/AgentCircuitData.cs | 52 +++++++++++++++++------------------ 1 file changed, 26 insertions(+), 26 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index a8cbaf0..8c184c4 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -32,6 +32,18 @@ namespace OpenSim.Framework { public class AgentCircuitData { + public LLUUID AgentID; + public LLUUID BaseFolder; + public string CapsPath = String.Empty; + public bool child; + public uint circuitcode; + public string firstname; + public LLUUID InventoryFolder; + public string lastname; + public LLUUID SecureSessionID; + public LLUUID SessionID; + public LLVector3 startpos; + public AgentCircuitData() { } @@ -50,23 +62,25 @@ namespace OpenSim.Framework BaseFolder = new LLUUID(cAgent.BaseFolder); CapsPath = cAgent.CapsPath; } - - public LLUUID AgentID; - public LLUUID SessionID; - public LLUUID SecureSessionID; - public LLVector3 startpos; - public string firstname; - public string lastname; - public uint circuitcode; - public bool child; - public LLUUID InventoryFolder; - public LLUUID BaseFolder; - public string CapsPath = String.Empty; } [Serializable] public class sAgentCircuitData { + public Guid AgentID; + public Guid BaseFolder; + public string CapsPath = String.Empty; + public bool child; + public uint circuitcode; + public string firstname; + public Guid InventoryFolder; + public string lastname; + public Guid SecureSessionID; + public Guid SessionID; + public float startposx; + public float startposy; + public float startposz; + public sAgentCircuitData() { } @@ -87,19 +101,5 @@ namespace OpenSim.Framework BaseFolder = cAgent.BaseFolder.UUID; CapsPath = cAgent.CapsPath; } - - public Guid AgentID; - public Guid SessionID; - public Guid SecureSessionID; - public float startposx; - public float startposy; - public float startposz; - public string firstname; - public string lastname; - public uint circuitcode; - public bool child; - public Guid InventoryFolder; - public Guid BaseFolder; - public string CapsPath = String.Empty; } } \ No newline at end of file -- cgit v1.1 From 7d89e122930be39e84a6d174548fa2d12ac0484a Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Sat, 6 Sep 2008 07:52:41 +0000 Subject: * This is the fabled LibOMV update with all of the libOMV types from JHurliman * This is a HUGE OMG update and will definitely have unknown side effects.. so this is really only for the strong hearted at this point. Regular people should let the dust settle. * This has been tested to work with most basic functions. However.. make sure you back up 'everything' before using this. It's that big! * Essentially we're back at square 1 in the testing phase.. so lets identify things that broke. --- OpenSim/Framework/AgentCircuitData.cs | 38 +++++++++++++++++------------------ 1 file changed, 19 insertions(+), 19 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 8c184c4..045bd00 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -26,23 +26,23 @@ */ using System; -using libsecondlife; +using OpenMetaverse; namespace OpenSim.Framework { public class AgentCircuitData { - public LLUUID AgentID; - public LLUUID BaseFolder; + public UUID AgentID; + public UUID BaseFolder; public string CapsPath = String.Empty; public bool child; public uint circuitcode; public string firstname; - public LLUUID InventoryFolder; + public UUID InventoryFolder; public string lastname; - public LLUUID SecureSessionID; - public LLUUID SessionID; - public LLVector3 startpos; + public UUID SecureSessionID; + public UUID SessionID; + public Vector3 startpos; public AgentCircuitData() { @@ -50,16 +50,16 @@ namespace OpenSim.Framework public AgentCircuitData(sAgentCircuitData cAgent) { - AgentID = new LLUUID(cAgent.AgentID); - SessionID = new LLUUID(cAgent.SessionID); - SecureSessionID = new LLUUID(cAgent.SecureSessionID); - startpos = new LLVector3(cAgent.startposx, cAgent.startposy, cAgent.startposz); + AgentID = new UUID(cAgent.AgentID); + SessionID = new UUID(cAgent.SessionID); + SecureSessionID = new UUID(cAgent.SecureSessionID); + startpos = new Vector3(cAgent.startposx, cAgent.startposy, cAgent.startposz); firstname = cAgent.firstname; lastname = cAgent.lastname; circuitcode = cAgent.circuitcode; child = cAgent.child; - InventoryFolder = new LLUUID(cAgent.InventoryFolder); - BaseFolder = new LLUUID(cAgent.BaseFolder); + InventoryFolder = new UUID(cAgent.InventoryFolder); + BaseFolder = new UUID(cAgent.BaseFolder); CapsPath = cAgent.CapsPath; } } @@ -87,9 +87,9 @@ namespace OpenSim.Framework public sAgentCircuitData(AgentCircuitData cAgent) { - AgentID = cAgent.AgentID.UUID; - SessionID = cAgent.SessionID.UUID; - SecureSessionID = cAgent.SecureSessionID.UUID; + AgentID = cAgent.AgentID.Guid; + SessionID = cAgent.SessionID.Guid; + SecureSessionID = cAgent.SecureSessionID.Guid; startposx = cAgent.startpos.X; startposy = cAgent.startpos.Y; startposz = cAgent.startpos.Z; @@ -97,9 +97,9 @@ namespace OpenSim.Framework lastname = cAgent.lastname; circuitcode = cAgent.circuitcode; child = cAgent.child; - InventoryFolder = cAgent.InventoryFolder.UUID; - BaseFolder = cAgent.BaseFolder.UUID; + InventoryFolder = cAgent.InventoryFolder.Guid; + BaseFolder = cAgent.BaseFolder.Guid; CapsPath = cAgent.CapsPath; } } -} \ No newline at end of file +} -- cgit v1.1 From e6eb571c1d19972fe7eb4c3f7de113b1b91f5e02 Mon Sep 17 00:00:00 2001 From: Charles Krinke Date: Sun, 14 Dec 2008 02:17:12 +0000 Subject: Mantis#2725. Thank you kindly, Diva, for a patch that: Adds missing protocol pieces for EstablishAgentCommunication event which allows the client to activate CAPS and the EQ for child agents. --- OpenSim/Framework/AgentCircuitData.cs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 045bd00..2671e87 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -26,6 +26,7 @@ */ using System; +using System.Collections.Generic; using OpenMetaverse; namespace OpenSim.Framework @@ -35,6 +36,7 @@ namespace OpenSim.Framework public UUID AgentID; public UUID BaseFolder; public string CapsPath = String.Empty; + public Dictionary ChildrenCapSeeds; public bool child; public uint circuitcode; public string firstname; @@ -61,6 +63,7 @@ namespace OpenSim.Framework InventoryFolder = new UUID(cAgent.InventoryFolder); BaseFolder = new UUID(cAgent.BaseFolder); CapsPath = cAgent.CapsPath; + ChildrenCapSeeds = cAgent.ChildrenCapSeeds; } } @@ -70,6 +73,7 @@ namespace OpenSim.Framework public Guid AgentID; public Guid BaseFolder; public string CapsPath = String.Empty; + public Dictionary ChildrenCapSeeds; public bool child; public uint circuitcode; public string firstname; @@ -100,6 +104,7 @@ namespace OpenSim.Framework InventoryFolder = cAgent.InventoryFolder.Guid; BaseFolder = cAgent.BaseFolder.Guid; CapsPath = cAgent.CapsPath; + ChildrenCapSeeds = cAgent.ChildrenCapSeeds; } } } -- cgit v1.1 From 1b7ce1c8747877a90de21aeb4b9ab901e55c2834 Mon Sep 17 00:00:00 2001 From: diva Date: Sat, 3 Jan 2009 03:41:41 +0000 Subject: Plumbing for moving InformRegionOfChildAgent over to RESTComms: pack and unpack methods for AgentCircuitData. This code is not used yet. --- OpenSim/Framework/AgentCircuitData.cs | 84 +++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 2671e87..9d40af9 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -28,6 +28,10 @@ using System; using System.Collections.Generic; using OpenMetaverse; +using OSD = OpenMetaverse.StructuredData.OSD; +using OSDMap = OpenMetaverse.StructuredData.OSDMap; +using OSDArray = OpenMetaverse.StructuredData.OSDArray; +using OSDParser = OpenMetaverse.StructuredData.OSDParser; namespace OpenSim.Framework { @@ -65,6 +69,86 @@ namespace OpenSim.Framework CapsPath = cAgent.CapsPath; ChildrenCapSeeds = cAgent.ChildrenCapSeeds; } + + public OSDMap PackAgentCircuitData() + { + OSDMap args = new OSDMap(); + args["agent_id"] = OSD.FromUUID(AgentID); + args["base_folder"] = OSD.FromUUID(BaseFolder); + args["caps_path"] = OSD.FromString(CapsPath); + + OSDArray childrenSeeds = new OSDArray(ChildrenCapSeeds.Count); + foreach (KeyValuePair kvp in ChildrenCapSeeds) + { + OSDMap pair = new OSDMap(); + pair["handle"] = OSD.FromString(kvp.Key.ToString()); + pair["seed"] = OSD.FromString(kvp.Value); + childrenSeeds.Add(pair); + } + args["children_seeds"] = childrenSeeds; + + args["child"] = OSD.FromBoolean(child); + args["circuit_code"] = OSD.FromString(circuitcode.ToString()); + args["first_name"] = OSD.FromString(firstname); + args["last_name"] = OSD.FromString(lastname); + args["inventory_folder"] = OSD.FromUUID(InventoryFolder); + args["secure_session_id"] = OSD.FromUUID(SecureSessionID); + args["session_id"] = OSD.FromUUID(SessionID); + args["start_pos"] = OSD.FromString(startpos.ToString()); + + return args; + } + + public void UnpackAgentCircuitData(OSDMap args) + { + if (args["agent_id"] != null) + AgentID = args["agent_id"].AsUUID(); + if (args["base_folder"] != null) + BaseFolder = args["base_folder"].AsUUID(); + if (args["caps_path"] != null) + CapsPath = args["caps_path"].AsString(); + + if ((args["children_seeds"] != null) && (args["children_seeds"].Type == OpenMetaverse.StructuredData.OSDType.Array)) + { + OSDArray childrenSeeds = (OSDArray)(args["children_seeds"]); + ChildrenCapSeeds = new Dictionary(); + foreach (OSD o in childrenSeeds) + { + if (o.Type == OpenMetaverse.StructuredData.OSDType.Map) + { + ulong handle = 0; + string seed = ""; + OSDMap pair = (OSDMap)o; + if (pair["handle"] != null) + if (!UInt64.TryParse(pair["handle"].AsString(), out handle)) + continue; + if (pair["seed"] != null) + seed = pair["seed"].AsString(); + if (!ChildrenCapSeeds.ContainsKey(handle)) + ChildrenCapSeeds.Add(handle, seed); + } + } + } + + if (args["child"] != null) + child = args["child"].AsBoolean(); + if (args["circuit_code"] != null) + UInt32.TryParse(args["circuit_code"].AsString(), out circuitcode); + if (args["first_name"] != null) + firstname = args["first_name"].AsString(); + if (args["last_name"] != null) + lastname = args["last_name"].AsString(); + if (args["inventory_folder"] != null) + InventoryFolder = args["inventory_folder"].AsUUID(); + if (args["secure_session_id"] != null) + SecureSessionID = args["secure_session_id"].AsUUID(); + if (args["session_id"] != null) + SessionID = args["session_id"].AsUUID(); + if (args["start_pos"] != null) + Vector3.TryParse(args["start_pos"].AsString(), out startpos); + + + } } [Serializable] -- cgit v1.1 From 801da4346aeb3c08969c4845f5c595135a64470a Mon Sep 17 00:00:00 2001 From: lbsa71 Date: Thu, 12 Feb 2009 09:53:12 +0000 Subject: * optimized usings. --- OpenSim/Framework/AgentCircuitData.cs | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 9d40af9..1c37601 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -28,10 +28,7 @@ using System; using System.Collections.Generic; using OpenMetaverse; -using OSD = OpenMetaverse.StructuredData.OSD; -using OSDMap = OpenMetaverse.StructuredData.OSDMap; -using OSDArray = OpenMetaverse.StructuredData.OSDArray; -using OSDParser = OpenMetaverse.StructuredData.OSDParser; +using OpenMetaverse.StructuredData; namespace OpenSim.Framework { @@ -108,13 +105,13 @@ namespace OpenSim.Framework if (args["caps_path"] != null) CapsPath = args["caps_path"].AsString(); - if ((args["children_seeds"] != null) && (args["children_seeds"].Type == OpenMetaverse.StructuredData.OSDType.Array)) + if ((args["children_seeds"] != null) && (args["children_seeds"].Type == OSDType.Array)) { OSDArray childrenSeeds = (OSDArray)(args["children_seeds"]); ChildrenCapSeeds = new Dictionary(); foreach (OSD o in childrenSeeds) { - if (o.Type == OpenMetaverse.StructuredData.OSDType.Map) + if (o.Type == OSDType.Map) { ulong handle = 0; string seed = ""; -- cgit v1.1 From 7cc906213795fbe4878c0cfb8351272e847617e9 Mon Sep 17 00:00:00 2001 From: diva Date: Tue, 17 Feb 2009 00:35:52 +0000 Subject: Major change to how appearance is managed, including changes in login and user service/server. Appearance is now sent by the user service/server along with all other loginparams. Regions don't query the user service for appearance anymore. The appearance is passed along from region to region as the avie moves around. And, as before, it's stored back with the user service as the client changes the avie's appearance. Child agents have default appearances that are set to the actual appearance when the avie moves to that region. (as before, child agents are invisible and non-physical). --- OpenSim/Framework/AgentCircuitData.cs | 1 + 1 file changed, 1 insertion(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 1c37601..bcd4c09 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -35,6 +35,7 @@ namespace OpenSim.Framework public class AgentCircuitData { public UUID AgentID; + public AvatarAppearance Appearance; public UUID BaseFolder; public string CapsPath = String.Empty; public Dictionary ChildrenCapSeeds; -- cgit v1.1 From 4eba67175db73bce439ea3f18242c4038d9acb92 Mon Sep 17 00:00:00 2001 From: diva Date: Thu, 12 Mar 2009 01:43:22 +0000 Subject: Minor bug fix. Thanks daTwitch. --- OpenSim/Framework/AgentCircuitData.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index bcd4c09..c0c910a 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -83,7 +83,8 @@ namespace OpenSim.Framework pair["seed"] = OSD.FromString(kvp.Value); childrenSeeds.Add(pair); } - args["children_seeds"] = childrenSeeds; + if (ChildrenCapSeeds.Count > 0) + args["children_seeds"] = childrenSeeds; args["child"] = OSD.FromBoolean(child); args["circuit_code"] = OSD.FromString(circuitcode.ToString()); -- cgit v1.1 From 840de6c036570d559ec6924cd8405d3f34a99fdd Mon Sep 17 00:00:00 2001 From: Jeff Ames Date: Mon, 1 Jun 2009 06:37:14 +0000 Subject: Minor: Change OpenSim to OpenSimulator in older copyright headers and LICENSE.txt. --- OpenSim/Framework/AgentCircuitData.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index c0c910a..c38f0c3 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -9,7 +9,7 @@ * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * * Neither the name of the OpenSim Project nor the + * * Neither the name of the OpenSimulator Project nor the * names of its contributors may be used to endorse or promote products * derived from this software without specific prior written permission. * -- cgit v1.1 From 18634e9dd8464ee7514587d0645e38f529f0bb3e Mon Sep 17 00:00:00 2001 From: Teravus Ovares (Dan Olivares) Date: Wed, 12 Aug 2009 23:18:00 -0400 Subject: minor: comments --- OpenSim/Framework/AgentCircuitData.cs | 68 +++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index c38f0c3..6472f31 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -32,26 +32,83 @@ using OpenMetaverse.StructuredData; namespace OpenSim.Framework { + /// + /// Circuit data for an agent. Connection information shared between + /// regions that accept UDP connections from a client + /// public class AgentCircuitData { + /// + /// Avatar Unique Agent Identifier + /// public UUID AgentID; + + /// + /// Avatar's Appearance + /// public AvatarAppearance Appearance; + + /// + /// Agent's root inventory folder + /// public UUID BaseFolder; + + /// + /// Base Caps path for user + /// public string CapsPath = String.Empty; + + /// + /// Seed caps for neighbor regions that the user can see into + /// public Dictionary ChildrenCapSeeds; + + /// + /// Root agent, or Child agent + /// public bool child; + + /// + /// Number given to the client when they log-in that they provide + /// as credentials to the UDP server + /// public uint circuitcode; + + /// + /// Agent's account first name + /// public string firstname; public UUID InventoryFolder; + + /// + /// Agent's account last name + /// public string lastname; + + /// + /// Random Unique GUID for this session. Client gets this at login and it's + /// only supposed to be disclosed over secure channels + /// public UUID SecureSessionID; + + /// + /// Non secure Session ID + /// public UUID SessionID; + + /// + /// Position the Agent's Avatar starts in the region + /// public Vector3 startpos; public AgentCircuitData() { } + /// + /// Create AgentCircuitData from a Serializable AgentCircuitData + /// + /// public AgentCircuitData(sAgentCircuitData cAgent) { AgentID = new UUID(cAgent.AgentID); @@ -68,6 +125,10 @@ namespace OpenSim.Framework ChildrenCapSeeds = cAgent.ChildrenCapSeeds; } + /// + /// Pack AgentCircuitData into an OSDMap for transmission over LLSD XML or LLSD json + /// + /// map of the agent circuit data public OSDMap PackAgentCircuitData() { OSDMap args = new OSDMap(); @@ -98,6 +159,10 @@ namespace OpenSim.Framework return args; } + /// + /// Unpack agent circuit data map into an AgentCiruitData object + /// + /// public void UnpackAgentCircuitData(OSDMap args) { if (args["agent_id"] != null) @@ -150,6 +215,9 @@ namespace OpenSim.Framework } } + /// + /// Serializable Agent Circuit Data + /// [Serializable] public class sAgentCircuitData { -- cgit v1.1 From e02062051d38e56ec22952e25a558039b5e54ab3 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Sun, 16 Aug 2009 16:17:19 -0700 Subject: Making attachments work again. Tons of debug more. This needs more testing and a lot of cleaning. --- OpenSim/Framework/AgentCircuitData.cs | 1 + 1 file changed, 1 insertion(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 6472f31..c0168e2 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -215,6 +215,7 @@ namespace OpenSim.Framework } } + /// /// Serializable Agent Circuit Data /// -- cgit v1.1 From 66920a9047b54db947d02f252e17409b7fc32ef0 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Tue, 12 Jan 2010 09:22:58 -0800 Subject: Fixed more appearance woes that showed up using remote connectors. Appearance is now being passed with AgentCircuitData, as it should be. --- OpenSim/Framework/AgentCircuitData.cs | 54 ++++++++++++++++++++++++++++++++++- 1 file changed, 53 insertions(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index c0168e2..ad29950 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -155,6 +155,31 @@ namespace OpenSim.Framework args["secure_session_id"] = OSD.FromUUID(SecureSessionID); args["session_id"] = OSD.FromUUID(SessionID); args["start_pos"] = OSD.FromString(startpos.ToString()); + args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); + + // We might not pass this in all cases... + if ((Appearance.Wearables != null) && (Appearance.Wearables.Length > 0)) + { + OSDArray wears = new OSDArray(Appearance.Wearables.Length); + foreach (AvatarWearable awear in Appearance.Wearables) + { + wears.Add(OSD.FromUUID(awear.ItemID)); + wears.Add(OSD.FromUUID(awear.AssetID)); + } + args["wearables"] = wears; + } + + Dictionary attachments = Appearance.GetAttachmentDictionary(); + if ((attachments != null) && (attachments.Count > 0)) + { + OSDArray attachs = new OSDArray(attachments.Count); + foreach (KeyValuePair kvp in attachments) + { + AttachmentData adata = new AttachmentData(kvp.Key, kvp.Value[0], kvp.Value[1]); + attachs.Add(adata.PackUpdateMessage()); + } + args["attachments"] = attachs; + } return args; } @@ -209,8 +234,35 @@ namespace OpenSim.Framework if (args["session_id"] != null) SessionID = args["session_id"].AsUUID(); if (args["start_pos"] != null) - Vector3.TryParse(args["start_pos"].AsString(), out startpos); + Vector3.TryParse(args["start_pos"].AsString(), out startpos); + Appearance = new AvatarAppearance(AgentID); + if (args["appearance_serial"] != null) + Appearance.Serial = args["appearance_serial"].AsInteger(); + if ((args["wearables"] != null) && (args["wearables"]).Type == OSDType.Array) + { + OSDArray wears = (OSDArray)(args["wearables"]); + for (int i = 0; i < wears.Count / 2; i++) + { + Appearance.Wearables[i].ItemID = wears[i*2].AsUUID(); + Appearance.Wearables[i].AssetID = wears[(i*2)+1].AsUUID(); + } + } + + if ((args["attachments"] != null) && (args["attachments"]).Type == OSDType.Array) + { + OSDArray attachs = (OSDArray)(args["attachments"]); + AttachmentData[] attachments = new AttachmentData[attachs.Count]; + int i = 0; + foreach (OSD o in attachs) + { + if (o.Type == OSDType.Map) + { + attachments[i++] = new AttachmentData((OSDMap)o); + } + } + Appearance.SetAttachments(attachments); + } } } -- cgit v1.1 From 4de82891a9c1219fd798fc005f5dea4dc7ea13f2 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Wed, 13 Jan 2010 09:34:08 -0800 Subject: Bug in Teleport fixed -- Appearance was missing from AgentCircuitData. --- OpenSim/Framework/AgentCircuitData.cs | 38 ++++++++++++++++++++--------------- 1 file changed, 22 insertions(+), 16 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index ad29950..e655aa4 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -157,28 +157,34 @@ namespace OpenSim.Framework args["start_pos"] = OSD.FromString(startpos.ToString()); args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); - // We might not pass this in all cases... - if ((Appearance.Wearables != null) && (Appearance.Wearables.Length > 0)) + if (Appearance != null) { - OSDArray wears = new OSDArray(Appearance.Wearables.Length); - foreach (AvatarWearable awear in Appearance.Wearables) + //System.Console.WriteLine("XXX Before packing Wearables"); + if ((Appearance.Wearables != null) && (Appearance.Wearables.Length > 0)) { - wears.Add(OSD.FromUUID(awear.ItemID)); - wears.Add(OSD.FromUUID(awear.AssetID)); + OSDArray wears = new OSDArray(Appearance.Wearables.Length * 2); + foreach (AvatarWearable awear in Appearance.Wearables) + { + wears.Add(OSD.FromUUID(awear.ItemID)); + wears.Add(OSD.FromUUID(awear.AssetID)); + //System.Console.WriteLine("XXX ItemID=" + awear.ItemID + " assetID=" + awear.AssetID); + } + args["wearables"] = wears; } - args["wearables"] = wears; - } - Dictionary attachments = Appearance.GetAttachmentDictionary(); - if ((attachments != null) && (attachments.Count > 0)) - { - OSDArray attachs = new OSDArray(attachments.Count); - foreach (KeyValuePair kvp in attachments) + //System.Console.WriteLine("XXX Before packing Attachments"); + Dictionary attachments = Appearance.GetAttachmentDictionary(); + if ((attachments != null) && (attachments.Count > 0)) { - AttachmentData adata = new AttachmentData(kvp.Key, kvp.Value[0], kvp.Value[1]); - attachs.Add(adata.PackUpdateMessage()); + OSDArray attachs = new OSDArray(attachments.Count); + foreach (KeyValuePair kvp in attachments) + { + AttachmentData adata = new AttachmentData(kvp.Key, kvp.Value[0], kvp.Value[1]); + attachs.Add(adata.PackUpdateMessage()); + //System.Console.WriteLine("XXX att.pt=" + kvp.Key + "; itemID=" + kvp.Value[0] + "; assetID=" + kvp.Value[1]); + } + args["attachments"] = attachs; } - args["attachments"] = attachs; } return args; -- cgit v1.1 From a7309d90dacf503b0170ad911289c33e9ab42821 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Sun, 17 Jan 2010 08:40:05 -0800 Subject: * Added ServiceURLs to AgentCircuitData. * Fixed a configuration buglet introduced yesterday in StandaloneHypergrid.ini. --- OpenSim/Framework/AgentCircuitData.cs | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index e655aa4..a3b999e 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -101,6 +101,8 @@ namespace OpenSim.Framework /// public Vector3 startpos; + public Dictionary ServiceURLs; + public AgentCircuitData() { } @@ -187,6 +189,16 @@ namespace OpenSim.Framework } } + if (ServiceURLs != null && ServiceURLs.Count > 0) + { + OSDArray urls = new OSDArray(ServiceURLs.Count * 2); + foreach (KeyValuePair kvp in ServiceURLs) + { + urls.Add(OSD.FromString(kvp.Key)); + urls.Add(OSD.FromString((kvp.Value == null) ? string.Empty : kvp.Value.ToString())); + } + } + return args; } @@ -270,6 +282,15 @@ namespace OpenSim.Framework Appearance.SetAttachments(attachments); } + ServiceURLs = new Dictionary(); + if (args.ContainsKey("service_urls") && args["service_urls"] != null && (args["service_urls"]).Type == OSDType.Array) + { + OSDArray urls = (OSDArray)(args["service_urls"]); + for (int i = 0; i < urls.Count / 2; i++) + { + ServiceURLs[urls[i * 2].AsString()] = urls[(i * 2) + 1].AsString(); + } + } } } -- cgit v1.1 From b2e6ec9e12ad07eb08496ebe8ca0476b793017d5 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Sun, 17 Jan 2010 18:04:55 -0800 Subject: Agent gets there through the Gatekeeper, but still a few quirks to fix. --- OpenSim/Framework/AgentCircuitData.cs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index a3b999e..f2f0a53 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -194,9 +194,11 @@ namespace OpenSim.Framework OSDArray urls = new OSDArray(ServiceURLs.Count * 2); foreach (KeyValuePair kvp in ServiceURLs) { + //System.Console.WriteLine("XXX " + kvp.Key + "=" + kvp.Value); urls.Add(OSD.FromString(kvp.Key)); urls.Add(OSD.FromString((kvp.Value == null) ? string.Empty : kvp.Value.ToString())); } + args["service_urls"] = urls; } return args; @@ -289,6 +291,8 @@ namespace OpenSim.Framework for (int i = 0; i < urls.Count / 2; i++) { ServiceURLs[urls[i * 2].AsString()] = urls[(i * 2) + 1].AsString(); + //System.Console.WriteLine("XXX " + urls[i * 2].AsString() + "=" + urls[(i * 2) + 1].AsString()); + } } } -- cgit v1.1 From 7c00469cd210cfdda3dd835867469159d4c8b9d9 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Wed, 27 Jan 2010 08:00:29 -0800 Subject: Added ExternalName config on Gatekeeper. --- OpenSim/Framework/AgentCircuitData.cs | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index f2f0a53..142ca2c 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -97,6 +97,12 @@ namespace OpenSim.Framework public UUID SessionID; /// + /// Hypergrid service token; generated by the user domain, consumed by the receiving grid. + /// There is one such unique token for each grid visited. + /// + public string ServiceSessionID = string.Empty; + + /// /// Position the Agent's Avatar starts in the region /// public Vector3 startpos; @@ -156,6 +162,7 @@ namespace OpenSim.Framework args["inventory_folder"] = OSD.FromUUID(InventoryFolder); args["secure_session_id"] = OSD.FromUUID(SecureSessionID); args["session_id"] = OSD.FromUUID(SessionID); + args["service_session_id"] = OSD.FromString(ServiceSessionID); args["start_pos"] = OSD.FromString(startpos.ToString()); args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); @@ -253,6 +260,8 @@ namespace OpenSim.Framework SecureSessionID = args["secure_session_id"].AsUUID(); if (args["session_id"] != null) SessionID = args["session_id"].AsUUID(); + if (args["service_session_id"] != null) + ServiceSessionID = args["service_session_id"].AsString(); if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); -- cgit v1.1 From 00f7d622cbc2c2e61d2efaacd8275da3f9821d8b Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Thu, 28 Jan 2010 19:19:42 -0800 Subject: HG 1.5 is in place. Tested in standalone only. --- OpenSim/Framework/AgentCircuitData.cs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 142ca2c..9c9b4b0 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -75,6 +75,11 @@ namespace OpenSim.Framework public uint circuitcode; /// + /// How this agent got here + /// + public uint teleportFlags; + + /// /// Agent's account first name /// public string firstname; -- cgit v1.1 From 0c81966c0a8f69474fb542d7b4df1780ef756519 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Fri, 29 Jan 2010 09:12:22 -0800 Subject: Works for grid login. --- OpenSim/Framework/AgentCircuitData.cs | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 9c9b4b0..353e5bf 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -149,17 +149,19 @@ namespace OpenSim.Framework args["base_folder"] = OSD.FromUUID(BaseFolder); args["caps_path"] = OSD.FromString(CapsPath); - OSDArray childrenSeeds = new OSDArray(ChildrenCapSeeds.Count); - foreach (KeyValuePair kvp in ChildrenCapSeeds) + if (ChildrenCapSeeds != null) { - OSDMap pair = new OSDMap(); - pair["handle"] = OSD.FromString(kvp.Key.ToString()); - pair["seed"] = OSD.FromString(kvp.Value); - childrenSeeds.Add(pair); + OSDArray childrenSeeds = new OSDArray(ChildrenCapSeeds.Count); + foreach (KeyValuePair kvp in ChildrenCapSeeds) + { + OSDMap pair = new OSDMap(); + pair["handle"] = OSD.FromString(kvp.Key.ToString()); + pair["seed"] = OSD.FromString(kvp.Value); + childrenSeeds.Add(pair); + } + if (ChildrenCapSeeds.Count > 0) + args["children_seeds"] = childrenSeeds; } - if (ChildrenCapSeeds.Count > 0) - args["children_seeds"] = childrenSeeds; - args["child"] = OSD.FromBoolean(child); args["circuit_code"] = OSD.FromString(circuitcode.ToString()); args["first_name"] = OSD.FromString(firstname); @@ -167,6 +169,7 @@ namespace OpenSim.Framework args["inventory_folder"] = OSD.FromUUID(InventoryFolder); args["secure_session_id"] = OSD.FromUUID(SecureSessionID); args["session_id"] = OSD.FromUUID(SessionID); + args["service_session_id"] = OSD.FromString(ServiceSessionID); args["start_pos"] = OSD.FromString(startpos.ToString()); args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); @@ -250,6 +253,8 @@ namespace OpenSim.Framework } } } + else + ChildrenCapSeeds = new Dictionary(); if (args["child"] != null) child = args["child"].AsBoolean(); @@ -267,6 +272,7 @@ namespace OpenSim.Framework SessionID = args["session_id"].AsUUID(); if (args["service_session_id"] != null) ServiceSessionID = args["service_session_id"].AsString(); + if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); -- cgit v1.1 From 2ebe1482664533bb9b9040134fe4a23fbc939d51 Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Thu, 6 May 2010 00:34:49 +0200 Subject: Plumb the viewer version string through into AgentCircuitData. Now all that is left os to figure out what black magic turns AgentCircuitData into AgentData and then copy that into the ScenePresence, where m_Viewer is already added with this commit and waits for the data. --- OpenSim/Framework/AgentCircuitData.cs | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 353e5bf..783a833 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -108,6 +108,11 @@ namespace OpenSim.Framework public string ServiceSessionID = string.Empty; /// + /// Viewer's version string + /// + public string Viewer; + + /// /// Position the Agent's Avatar starts in the region /// public Vector3 startpos; @@ -136,6 +141,7 @@ namespace OpenSim.Framework BaseFolder = new UUID(cAgent.BaseFolder); CapsPath = cAgent.CapsPath; ChildrenCapSeeds = cAgent.ChildrenCapSeeds; + Viewer = cAgent.Viewer; } /// @@ -173,6 +179,7 @@ namespace OpenSim.Framework args["service_session_id"] = OSD.FromString(ServiceSessionID); args["start_pos"] = OSD.FromString(startpos.ToString()); args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); + args["viewer"] = OSD.FromString(Viewer); if (Appearance != null) { @@ -272,6 +279,8 @@ namespace OpenSim.Framework SessionID = args["session_id"].AsUUID(); if (args["service_session_id"] != null) ServiceSessionID = args["service_session_id"].AsString(); + if (args["viewer"] != null) + Viewer = args["viewer"].AsString(); if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); @@ -339,6 +348,7 @@ namespace OpenSim.Framework public float startposx; public float startposy; public float startposz; + public string Viewer; public sAgentCircuitData() { @@ -360,6 +370,7 @@ namespace OpenSim.Framework BaseFolder = cAgent.BaseFolder.Guid; CapsPath = cAgent.CapsPath; ChildrenCapSeeds = cAgent.ChildrenCapSeeds; + Viewer = cAgent.Viewer; } } } -- cgit v1.1 From 0772e19af25b8524fa2527a4d5f3bac496d07811 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Sun, 3 Oct 2010 20:01:59 -0700 Subject: Added viewer's channel, mac, and id0 to agent circuit data. Also moved client ip address to agent circuit data, so that it's always there. --- OpenSim/Framework/AgentCircuitData.cs | 37 ++++++++++++++++++++++++++++++++++- 1 file changed, 36 insertions(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 783a833..4f89d78 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -108,11 +108,31 @@ namespace OpenSim.Framework public string ServiceSessionID = string.Empty; /// - /// Viewer's version string + /// The client's IP address, as captured by the login service + /// + public string IPAddress; + + /// + /// Viewer's version string as reported by the viewer at login /// public string Viewer; /// + /// The channel strinf sent by the viewer at login + /// + public string Channel; + + /// + /// The Mac address as reported by the viewer at login + /// + public string Mac; + + /// + /// The id0 as reported by the viewer at login + /// + public string Id0; + + /// /// Position the Agent's Avatar starts in the region /// public Vector3 startpos; @@ -179,7 +199,11 @@ namespace OpenSim.Framework args["service_session_id"] = OSD.FromString(ServiceSessionID); args["start_pos"] = OSD.FromString(startpos.ToString()); args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); + args["client_ip"] = OSD.FromString(IPAddress); args["viewer"] = OSD.FromString(Viewer); + args["channel"] = OSD.FromString(Channel); + args["mac"] = OSD.FromString(Mac); + args["id0"] = OSD.FromString(Id0); if (Appearance != null) { @@ -279,8 +303,16 @@ namespace OpenSim.Framework SessionID = args["session_id"].AsUUID(); if (args["service_session_id"] != null) ServiceSessionID = args["service_session_id"].AsString(); + if (args["client_ip"] != null) + IPAddress = args["client_ip"].AsString(); if (args["viewer"] != null) Viewer = args["viewer"].AsString(); + if (args["channel"] != null) + Channel = args["channel"].AsString(); + if (args["mac"] != null) + Mac = args["mac"].AsString(); + if (args["id0"] != null) + Id0 = args["id0"].AsString(); if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); @@ -349,6 +381,9 @@ namespace OpenSim.Framework public float startposy; public float startposz; public string Viewer; + public string Channel; + public string Mac; + public string Id0; public sAgentCircuitData() { -- cgit v1.1 From b1c8d0588829dfa76f89460eeb8406d9c4fc479f Mon Sep 17 00:00:00 2001 From: Master ScienceSim Date: Wed, 20 Oct 2010 16:17:54 -0700 Subject: Major refactoring of appearance handling. AvatarService -- add two new methods, GetAppearance and SetAppearance to get around the lossy encoding in AvatarData. Preseve the old functions to avoid changing the behavior for ROBUST services. AvatarAppearance -- major refactor, moved the various encoding methods used by AgentCircuitData, ClientAgentUpdate and ScenePresence into one location. Changed initialization. AvatarAttachments -- added a class specifically to handle attachments in preparation for additional functionality that will be needed for viewer 2. AvatarFactory -- removed a number of unused or methods duplicated in other locations. Moved in all appearance event handling from ScenePresence. Required a change to IClientAPI that propogated throughout all the IClientAPI implementations. --- OpenSim/Framework/AgentCircuitData.cs | 61 +++++++++++++++++++++++++++++------ 1 file changed, 52 insertions(+), 9 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 4f89d78..be98380 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -26,7 +26,9 @@ */ using System; +using System.Reflection; using System.Collections.Generic; +using log4net; using OpenMetaverse; using OpenMetaverse.StructuredData; @@ -38,6 +40,12 @@ namespace OpenSim.Framework /// public class AgentCircuitData { +// DEBUG ON + private static readonly ILog m_log = + LogManager.GetLogger( + MethodBase.GetCurrentMethod().DeclaringType); +// DEBUG OFF + /// /// Avatar Unique Agent Identifier /// @@ -205,6 +213,7 @@ namespace OpenSim.Framework args["mac"] = OSD.FromString(Mac); args["id0"] = OSD.FromString(Id0); +/* if (Appearance != null) { //System.Console.WriteLine("XXX Before packing Wearables"); @@ -221,20 +230,26 @@ namespace OpenSim.Framework } //System.Console.WriteLine("XXX Before packing Attachments"); - Dictionary attachments = Appearance.GetAttachmentDictionary(); + Dictionary attachments = Appearance.Attachments; if ((attachments != null) && (attachments.Count > 0)) { OSDArray attachs = new OSDArray(attachments.Count); - foreach (KeyValuePair kvp in attachments) + foreach (KeyValuePair kvp in attachments) { - AttachmentData adata = new AttachmentData(kvp.Key, kvp.Value[0], kvp.Value[1]); - attachs.Add(adata.PackUpdateMessage()); + AvatarAttachment adata = new AvatarAttachment(kvp.Value); + attachs.Add(adata.Pack()); //System.Console.WriteLine("XXX att.pt=" + kvp.Key + "; itemID=" + kvp.Value[0] + "; assetID=" + kvp.Value[1]); } args["attachments"] = attachs; } } - +*/ + if (Appearance != null) + { + OSDMap appmap = Appearance.Pack(); + args["packed_appearance"] = appmap; + } + if (ServiceURLs != null && ServiceURLs.Count > 0) { OSDArray urls = new OSDArray(ServiceURLs.Count * 2); @@ -317,9 +332,37 @@ namespace OpenSim.Framework if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); +// DEBUG ON + m_log.WarnFormat("[AGENTCIRCUITDATA] agentid={0}, child={1}, startpos={2}",AgentID,child,startpos.ToString()); +// DEBUG OFF + + try { + // Unpack various appearance elements Appearance = new AvatarAppearance(AgentID); + if (args["packed_appearance"] != null) + { + if (args["packed_appearance"].Type == OSDType.Map) + { + Appearance.Unpack((OSDMap)args["packed_appearance"]); + m_log.WarnFormat("[AGENTCIRCUITDATA] unpacked appearance"); + } + else + m_log.WarnFormat("[AGENTCIRCUITDATA] packed_appearance is not a map:\n{0}",args["packed_appearance"].ToString()); + } +// DEBUG ON + else + m_log.Warn("[AGENTCIRCUITDATA] failed to find a valid packed_appearance"); +// DEBUG OFF + } catch (Exception e) + { + m_log.ErrorFormat("[AGENTCIRCUITDATA] failed to unpack appearance; {0}",e.Message); + } + + +/* if (args["appearance_serial"] != null) Appearance.Serial = args["appearance_serial"].AsInteger(); + if ((args["wearables"] != null) && (args["wearables"]).Type == OSDType.Array) { OSDArray wears = (OSDArray)(args["wearables"]); @@ -328,23 +371,23 @@ namespace OpenSim.Framework Appearance.Wearables[i].ItemID = wears[i*2].AsUUID(); Appearance.Wearables[i].AssetID = wears[(i*2)+1].AsUUID(); } - } + } if ((args["attachments"] != null) && (args["attachments"]).Type == OSDType.Array) { OSDArray attachs = (OSDArray)(args["attachments"]); - AttachmentData[] attachments = new AttachmentData[attachs.Count]; + AvatarAttachment[] attachments = new AvatarAttachment[attachs.Count]; int i = 0; foreach (OSD o in attachs) { if (o.Type == OSDType.Map) { - attachments[i++] = new AttachmentData((OSDMap)o); + attachments[i++] = new AvatarAttachment((OSDMap)o); } } Appearance.SetAttachments(attachments); } - +*/ ServiceURLs = new Dictionary(); if (args.ContainsKey("service_urls") && args["service_urls"] != null && (args["service_urls"]).Type == OSDType.Array) { -- cgit v1.1 From 657cceb8847f94a9af0c8b2358124105d778486c Mon Sep 17 00:00:00 2001 From: Mic Bowman Date: Mon, 25 Oct 2010 09:41:08 -0700 Subject: Intermediate commit for backward compatability; does not compile yet --- OpenSim/Framework/AgentCircuitData.cs | 65 +++++++++++++++++------------------ 1 file changed, 32 insertions(+), 33 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index be98380..30a9548 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -206,16 +206,18 @@ namespace OpenSim.Framework args["service_session_id"] = OSD.FromString(ServiceSessionID); args["start_pos"] = OSD.FromString(startpos.ToString()); - args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); args["client_ip"] = OSD.FromString(IPAddress); args["viewer"] = OSD.FromString(Viewer); args["channel"] = OSD.FromString(Channel); args["mac"] = OSD.FromString(Mac); args["id0"] = OSD.FromString(Id0); -/* + // Eventually this code should be deprecated, use full appearance + // packing in packed_appearance if (Appearance != null) { + args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); + //System.Console.WriteLine("XXX Before packing Wearables"); if ((Appearance.Wearables != null) && (Appearance.Wearables.Length > 0)) { @@ -230,20 +232,19 @@ namespace OpenSim.Framework } //System.Console.WriteLine("XXX Before packing Attachments"); - Dictionary attachments = Appearance.Attachments; + List attachments = Appearance.GetAttachments(); if ((attachments != null) && (attachments.Count > 0)) { OSDArray attachs = new OSDArray(attachments.Count); - foreach (KeyValuePair kvp in attachments) + foreach (AvatarAttachment attach in attachments) { - AvatarAttachment adata = new AvatarAttachment(kvp.Value); - attachs.Add(adata.Pack()); + attachs.Add(attach.Pack()); //System.Console.WriteLine("XXX att.pt=" + kvp.Key + "; itemID=" + kvp.Value[0] + "; assetID=" + kvp.Value[1]); } args["attachments"] = attachs; } } -*/ + if (Appearance != null) { OSDMap appmap = Appearance.Pack(); @@ -339,27 +340,9 @@ namespace OpenSim.Framework try { // Unpack various appearance elements Appearance = new AvatarAppearance(AgentID); - if (args["packed_appearance"] != null) - { - if (args["packed_appearance"].Type == OSDType.Map) - { - Appearance.Unpack((OSDMap)args["packed_appearance"]); - m_log.WarnFormat("[AGENTCIRCUITDATA] unpacked appearance"); - } - else - m_log.WarnFormat("[AGENTCIRCUITDATA] packed_appearance is not a map:\n{0}",args["packed_appearance"].ToString()); - } -// DEBUG ON - else - m_log.Warn("[AGENTCIRCUITDATA] failed to find a valid packed_appearance"); -// DEBUG OFF - } catch (Exception e) - { - m_log.ErrorFormat("[AGENTCIRCUITDATA] failed to unpack appearance; {0}",e.Message); - } - - -/* + + // Eventually this code should be deprecated, use full appearance + // packing in packed_appearance if (args["appearance_serial"] != null) Appearance.Serial = args["appearance_serial"].AsInteger(); @@ -376,18 +359,34 @@ namespace OpenSim.Framework if ((args["attachments"] != null) && (args["attachments"]).Type == OSDType.Array) { OSDArray attachs = (OSDArray)(args["attachments"]); - AvatarAttachment[] attachments = new AvatarAttachment[attachs.Count]; - int i = 0; foreach (OSD o in attachs) { if (o.Type == OSDType.Map) { - attachments[i++] = new AvatarAttachment((OSDMap)o); + Appearance.AppendAttachment(new AvatarAttachment((OSDMap)o)); } } - Appearance.SetAttachments(attachments); } -*/ + + if (args["packed_appearance"] != null) + { + if (args["packed_appearance"].Type == OSDType.Map) + { + Appearance.Unpack((OSDMap)args["packed_appearance"]); + m_log.WarnFormat("[AGENTCIRCUITDATA] unpacked appearance"); + } + else + m_log.WarnFormat("[AGENTCIRCUITDATA] packed_appearance is not a map:\n{0}",args["packed_appearance"].ToString()); + } +// DEBUG ON + else + m_log.Warn("[AGENTCIRCUITDATA] failed to find a valid packed_appearance"); +// DEBUG OFF + } catch (Exception e) + { + m_log.ErrorFormat("[AGENTCIRCUITDATA] failed to unpack appearance; {0}",e.Message); + } + ServiceURLs = new Dictionary(); if (args.ContainsKey("service_urls") && args["service_urls"] != null && (args["service_urls"]).Type == OSDType.Array) { -- cgit v1.1 From 6e58c3d563b50c5797d1cfffbaec3fe82f18c2ea Mon Sep 17 00:00:00 2001 From: Master ScienceSim Date: Mon, 25 Oct 2010 14:11:47 -0700 Subject: Half of the compatibility is working. Login into a new region with old data works. Teleport out of a new region with old data works. Teleport into a new region with old data does not trigger the necessary rebake. --- OpenSim/Framework/AgentCircuitData.cs | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 30a9548..098b33c 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -368,15 +368,12 @@ namespace OpenSim.Framework } } - if (args["packed_appearance"] != null) + if (args.ContainsKey("packed_appearance") && (args["packed_appearance"].Type == OSDType.Map)) { - if (args["packed_appearance"].Type == OSDType.Map) - { - Appearance.Unpack((OSDMap)args["packed_appearance"]); - m_log.WarnFormat("[AGENTCIRCUITDATA] unpacked appearance"); - } - else - m_log.WarnFormat("[AGENTCIRCUITDATA] packed_appearance is not a map:\n{0}",args["packed_appearance"].ToString()); + Appearance.Unpack((OSDMap)args["packed_appearance"]); +// DEBUG ON + m_log.WarnFormat("[AGENTCIRCUITDATA] unpacked appearance"); +// DEBUG OFF } // DEBUG ON else -- cgit v1.1 From 9cfd3e1d5ac8383087fb09cf076e9ec199808fd7 Mon Sep 17 00:00:00 2001 From: Master ScienceSim Date: Tue, 26 Oct 2010 12:54:28 -0700 Subject: Small cleanup and add more debugging information --- OpenSim/Framework/AgentCircuitData.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 098b33c..640a646 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -351,8 +351,8 @@ namespace OpenSim.Framework OSDArray wears = (OSDArray)(args["wearables"]); for (int i = 0; i < wears.Count / 2; i++) { - Appearance.Wearables[i].ItemID = wears[i*2].AsUUID(); - Appearance.Wearables[i].AssetID = wears[(i*2)+1].AsUUID(); + AvatarWearable awear = new AvatarWearable(wears[i*2].AsUUID(),wears[(i*2)+1].AsUUID()); + Appearance.SetWearable(i,awear); } } -- cgit v1.1 From 818ed2032aa4e6c0a9ede3598d64f0c7960135c4 Mon Sep 17 00:00:00 2001 From: Melanie Date: Sat, 30 Oct 2010 00:41:36 +0100 Subject: READ CAREFULLY!!! This is a BROKEN commit. It is UNTESTED and INCOMPLETE. It contains a major interface version bump and will NOT work with earlier grid services. This is preliminary work that will lead to layers support. Rest appearance services are commented out completely, they will have to be adapted by someone who actually uses them. Remote admin is working, but has no layers support. There is no layers support in the database. Login likely won't work. You have been warned. --- OpenSim/Framework/AgentCircuitData.cs | 51 ----------------------------------- 1 file changed, 51 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 640a646..cd30c3d 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -218,35 +218,6 @@ namespace OpenSim.Framework { args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); - //System.Console.WriteLine("XXX Before packing Wearables"); - if ((Appearance.Wearables != null) && (Appearance.Wearables.Length > 0)) - { - OSDArray wears = new OSDArray(Appearance.Wearables.Length * 2); - foreach (AvatarWearable awear in Appearance.Wearables) - { - wears.Add(OSD.FromUUID(awear.ItemID)); - wears.Add(OSD.FromUUID(awear.AssetID)); - //System.Console.WriteLine("XXX ItemID=" + awear.ItemID + " assetID=" + awear.AssetID); - } - args["wearables"] = wears; - } - - //System.Console.WriteLine("XXX Before packing Attachments"); - List attachments = Appearance.GetAttachments(); - if ((attachments != null) && (attachments.Count > 0)) - { - OSDArray attachs = new OSDArray(attachments.Count); - foreach (AvatarAttachment attach in attachments) - { - attachs.Add(attach.Pack()); - //System.Console.WriteLine("XXX att.pt=" + kvp.Key + "; itemID=" + kvp.Value[0] + "; assetID=" + kvp.Value[1]); - } - args["attachments"] = attachs; - } - } - - if (Appearance != null) - { OSDMap appmap = Appearance.Pack(); args["packed_appearance"] = appmap; } @@ -346,28 +317,6 @@ namespace OpenSim.Framework if (args["appearance_serial"] != null) Appearance.Serial = args["appearance_serial"].AsInteger(); - if ((args["wearables"] != null) && (args["wearables"]).Type == OSDType.Array) - { - OSDArray wears = (OSDArray)(args["wearables"]); - for (int i = 0; i < wears.Count / 2; i++) - { - AvatarWearable awear = new AvatarWearable(wears[i*2].AsUUID(),wears[(i*2)+1].AsUUID()); - Appearance.SetWearable(i,awear); - } - } - - if ((args["attachments"] != null) && (args["attachments"]).Type == OSDType.Array) - { - OSDArray attachs = (OSDArray)(args["attachments"]); - foreach (OSD o in attachs) - { - if (o.Type == OSDType.Map) - { - Appearance.AppendAttachment(new AvatarAttachment((OSDMap)o)); - } - } - } - if (args.ContainsKey("packed_appearance") && (args["packed_appearance"].Type == OSDType.Map)) { Appearance.Unpack((OSDMap)args["packed_appearance"]); -- cgit v1.1 From adef6b04cb3e333df66bf2393eec9d25b2380dfd Mon Sep 17 00:00:00 2001 From: Melanie Date: Sat, 30 Oct 2010 02:52:59 +0100 Subject: Logins work now, but avatars are green ugly gnomes. --- OpenSim/Framework/AgentCircuitData.cs | 2 -- 1 file changed, 2 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index cd30c3d..7b14ac7 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -212,8 +212,6 @@ namespace OpenSim.Framework args["mac"] = OSD.FromString(Mac); args["id0"] = OSD.FromString(Id0); - // Eventually this code should be deprecated, use full appearance - // packing in packed_appearance if (Appearance != null) { args["appearance_serial"] = OSD.FromInteger(Appearance.Serial); -- cgit v1.1 From ae9c4a4d118e126b4f849bbfed112d0971459339 Mon Sep 17 00:00:00 2001 From: Jeff Ames Date: Mon, 8 Nov 2010 07:48:35 -0500 Subject: Formatting cleanup. --- OpenSim/Framework/AgentCircuitData.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 7b14ac7..cc9fcea 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -203,7 +203,7 @@ namespace OpenSim.Framework args["inventory_folder"] = OSD.FromUUID(InventoryFolder); args["secure_session_id"] = OSD.FromUUID(SecureSessionID); args["session_id"] = OSD.FromUUID(SessionID); - + args["service_session_id"] = OSD.FromString(ServiceSessionID); args["start_pos"] = OSD.FromString(startpos.ToString()); args["client_ip"] = OSD.FromString(IPAddress); @@ -219,7 +219,7 @@ namespace OpenSim.Framework OSDMap appmap = Appearance.Pack(); args["packed_appearance"] = appmap; } - + if (ServiceURLs != null && ServiceURLs.Count > 0) { OSDArray urls = new OSDArray(ServiceURLs.Count * 2); @@ -307,7 +307,7 @@ namespace OpenSim.Framework // DEBUG OFF try { - // Unpack various appearance elements + // Unpack various appearance elements Appearance = new AvatarAppearance(AgentID); // Eventually this code should be deprecated, use full appearance -- cgit v1.1 From 541a7660e06206c9a9eb2426dee0449afb554921 Mon Sep 17 00:00:00 2001 From: Mic Bowman Date: Tue, 23 Nov 2010 16:08:10 -0800 Subject: Refactor appearance and avatar data sending code. Paritioning the routines into "one-to-many" and "many-to-one" makes it possible to call the right function on presence creation (both child and root) and when a child agent is promoted to root. This brings the total number of appearance sends down to one or two on login. Cleaned up the avatar update calls in the groups code. Cleaned up some commented and debugging code, and a few formating fixes. --- OpenSim/Framework/AgentCircuitData.cs | 35 +++++++++++++++-------------------- 1 file changed, 15 insertions(+), 20 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index cc9fcea..1600bdc 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -302,31 +302,26 @@ namespace OpenSim.Framework if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); -// DEBUG ON - m_log.WarnFormat("[AGENTCIRCUITDATA] agentid={0}, child={1}, startpos={2}",AgentID,child,startpos.ToString()); -// DEBUG OFF + m_log.InfoFormat("[AGENTCIRCUITDATA] agentid={0}, child={1}, startpos={2}",AgentID,child,startpos.ToString()); try { - // Unpack various appearance elements - Appearance = new AvatarAppearance(AgentID); + // Unpack various appearance elements + Appearance = new AvatarAppearance(AgentID); - // Eventually this code should be deprecated, use full appearance - // packing in packed_appearance - if (args["appearance_serial"] != null) - Appearance.Serial = args["appearance_serial"].AsInteger(); + // Eventually this code should be deprecated, use full appearance + // packing in packed_appearance + if (args["appearance_serial"] != null) + Appearance.Serial = args["appearance_serial"].AsInteger(); - if (args.ContainsKey("packed_appearance") && (args["packed_appearance"].Type == OSDType.Map)) - { - Appearance.Unpack((OSDMap)args["packed_appearance"]); -// DEBUG ON - m_log.WarnFormat("[AGENTCIRCUITDATA] unpacked appearance"); -// DEBUG OFF + if (args.ContainsKey("packed_appearance") && (args["packed_appearance"].Type == OSDType.Map)) + { + Appearance.Unpack((OSDMap)args["packed_appearance"]); + m_log.InfoFormat("[AGENTCIRCUITDATA] unpacked appearance"); + } + else + m_log.Warn("[AGENTCIRCUITDATA] failed to find a valid packed_appearance"); } -// DEBUG ON - else - m_log.Warn("[AGENTCIRCUITDATA] failed to find a valid packed_appearance"); -// DEBUG OFF - } catch (Exception e) + catch (Exception e) { m_log.ErrorFormat("[AGENTCIRCUITDATA] failed to unpack appearance; {0}",e.Message); } -- cgit v1.1 From 3a2a48a8cad9914862b6804cb46b21bc2c8d6bf7 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Sat, 5 Feb 2011 08:20:13 -0800 Subject: Add sane packing of ServiceURLs -- OSDMap. The old way (OSDArray) is still supported for backwards compatibility, but will be removed in the future. --- OpenSim/Framework/AgentCircuitData.cs | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 1600bdc..3dbc215 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -220,6 +220,8 @@ namespace OpenSim.Framework args["packed_appearance"] = appmap; } + // Old, bad way. Keeping it fow now for backwards compatibility + // OBSOLETE -- soon to be deleted if (ServiceURLs != null && ServiceURLs.Count > 0) { OSDArray urls = new OSDArray(ServiceURLs.Count * 2); @@ -232,6 +234,19 @@ namespace OpenSim.Framework args["service_urls"] = urls; } + // again, this time the right way + if (ServiceURLs != null && ServiceURLs.Count > 0) + { + OSDMap urls = new OSDMap(); + foreach (KeyValuePair kvp in ServiceURLs) + { + //System.Console.WriteLine("XXX " + kvp.Key + "=" + kvp.Value); + urls[kvp.Key] = OSD.FromString((kvp.Value == null) ? string.Empty : kvp.Value.ToString()); + } + args["serviceurls"] = urls; + } + + return args; } @@ -327,7 +342,20 @@ namespace OpenSim.Framework } ServiceURLs = new Dictionary(); - if (args.ContainsKey("service_urls") && args["service_urls"] != null && (args["service_urls"]).Type == OSDType.Array) + // Try parse the new way, OSDMap + if (args.ContainsKey("serviceurls") && args["serviceurls"] != null && (args["serviceurls"]).Type == OSDType.Map) + { + OSDMap urls = (OSDMap)(args["serviceurls"]); + foreach (KeyValuePair kvp in urls) + { + ServiceURLs[kvp.Key] = kvp.Value.AsString(); + //System.Console.WriteLine("XXX " + kvp.Key + "=" + ServiceURLs[kvp.Key]); + + } + } + // else try the old way, OSDArray + // OBSOLETE -- soon to be deleted + else if (args.ContainsKey("service_urls") && args["service_urls"] != null && (args["service_urls"]).Type == OSDType.Array) { OSDArray urls = (OSDArray)(args["service_urls"]); for (int i = 0; i < urls.Count / 2; i++) -- cgit v1.1 From 549dc5aeb9e693f1f575896796d19b03ec3a732f Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Thu, 28 Apr 2011 08:58:04 -0700 Subject: Eliminated sAgentCircuitData, a data structure that has been obsolete for quite some time. --- OpenSim/Framework/AgentCircuitData.cs | 69 ----------------------------------- 1 file changed, 69 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 3dbc215..dbd47d3 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -152,27 +152,6 @@ namespace OpenSim.Framework } /// - /// Create AgentCircuitData from a Serializable AgentCircuitData - /// - /// - public AgentCircuitData(sAgentCircuitData cAgent) - { - AgentID = new UUID(cAgent.AgentID); - SessionID = new UUID(cAgent.SessionID); - SecureSessionID = new UUID(cAgent.SecureSessionID); - startpos = new Vector3(cAgent.startposx, cAgent.startposy, cAgent.startposz); - firstname = cAgent.firstname; - lastname = cAgent.lastname; - circuitcode = cAgent.circuitcode; - child = cAgent.child; - InventoryFolder = new UUID(cAgent.InventoryFolder); - BaseFolder = new UUID(cAgent.BaseFolder); - CapsPath = cAgent.CapsPath; - ChildrenCapSeeds = cAgent.ChildrenCapSeeds; - Viewer = cAgent.Viewer; - } - - /// /// Pack AgentCircuitData into an OSDMap for transmission over LLSD XML or LLSD json /// /// map of the agent circuit data @@ -369,52 +348,4 @@ namespace OpenSim.Framework } - /// - /// Serializable Agent Circuit Data - /// - [Serializable] - public class sAgentCircuitData - { - public Guid AgentID; - public Guid BaseFolder; - public string CapsPath = String.Empty; - public Dictionary ChildrenCapSeeds; - public bool child; - public uint circuitcode; - public string firstname; - public Guid InventoryFolder; - public string lastname; - public Guid SecureSessionID; - public Guid SessionID; - public float startposx; - public float startposy; - public float startposz; - public string Viewer; - public string Channel; - public string Mac; - public string Id0; - - public sAgentCircuitData() - { - } - - public sAgentCircuitData(AgentCircuitData cAgent) - { - AgentID = cAgent.AgentID.Guid; - SessionID = cAgent.SessionID.Guid; - SecureSessionID = cAgent.SecureSessionID.Guid; - startposx = cAgent.startpos.X; - startposy = cAgent.startpos.Y; - startposz = cAgent.startpos.Z; - firstname = cAgent.firstname; - lastname = cAgent.lastname; - circuitcode = cAgent.circuitcode; - child = cAgent.child; - InventoryFolder = cAgent.InventoryFolder.Guid; - BaseFolder = cAgent.BaseFolder.Guid; - CapsPath = cAgent.CapsPath; - ChildrenCapSeeds = cAgent.ChildrenCapSeeds; - Viewer = cAgent.Viewer; - } - } } -- cgit v1.1 From d21e9c755f004d8fe03b11bc57b810dbd401435a Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Thu, 19 May 2011 16:54:46 -0700 Subject: HG Friends working to some extent: friendships offered and accepted correctly handled. Friends list showing correct foreign names. TODO: GrantRights. --- OpenSim/Framework/AgentCircuitData.cs | 1 + 1 file changed, 1 insertion(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index dbd47d3..125910e 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -345,6 +345,7 @@ namespace OpenSim.Framework } } } + } -- cgit v1.1 From b6ac1c46cd473b129b70344f0001f1e8f97d8860 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Tue, 2 Aug 2011 00:13:04 +0100 Subject: Get rid of AvatarAppearance.Owner to simplify the code. This is not used for anything - appearances are always properties of objects with ids (ScenePresence, AgentCircuitData) and just has the potential to get out of sync when the appearance is cloned. --- OpenSim/Framework/AgentCircuitData.cs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 125910e..12c8ac0 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -296,11 +296,12 @@ namespace OpenSim.Framework if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); - m_log.InfoFormat("[AGENTCIRCUITDATA] agentid={0}, child={1}, startpos={2}",AgentID,child,startpos.ToString()); + m_log.InfoFormat("[AGENTCIRCUITDATA]: agentid={0}, child={1}, startpos={2}", AgentID, child, startpos); - try { + try + { // Unpack various appearance elements - Appearance = new AvatarAppearance(AgentID); + Appearance = new AvatarAppearance(); // Eventually this code should be deprecated, use full appearance // packing in packed_appearance @@ -313,7 +314,9 @@ namespace OpenSim.Framework m_log.InfoFormat("[AGENTCIRCUITDATA] unpacked appearance"); } else - m_log.Warn("[AGENTCIRCUITDATA] failed to find a valid packed_appearance"); + { + m_log.Warn("[AGENTCIRCUITDATA]: failed to find a valid packed_appearance"); + } } catch (Exception e) { -- cgit v1.1 From 0daa5d8b4d2127437b079c089a680dcbcf1c5268 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Fri, 9 Dec 2011 23:44:34 +0000 Subject: minor: comment out "unpacked appearance" log mesasge for now --- OpenSim/Framework/AgentCircuitData.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 12c8ac0..54e1bf7 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -311,7 +311,7 @@ namespace OpenSim.Framework if (args.ContainsKey("packed_appearance") && (args["packed_appearance"].Type == OSDType.Map)) { Appearance.Unpack((OSDMap)args["packed_appearance"]); - m_log.InfoFormat("[AGENTCIRCUITDATA] unpacked appearance"); +// m_log.InfoFormat("[AGENTCIRCUITDATA] unpacked appearance"); } else { -- cgit v1.1 From 99623894c79c6719a44b43741e722affe9f704cc Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Fri, 16 Dec 2011 17:23:30 -0800 Subject: Commented a couple of verbose debug messages. --- OpenSim/Framework/AgentCircuitData.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 54e1bf7..57fb808 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -296,7 +296,7 @@ namespace OpenSim.Framework if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); - m_log.InfoFormat("[AGENTCIRCUITDATA]: agentid={0}, child={1}, startpos={2}", AgentID, child, startpos); + //m_log.InfoFormat("[AGENTCIRCUITDATA]: agentid={0}, child={1}, startpos={2}", AgentID, child, startpos); try { -- cgit v1.1 From 15283d35f1c567d6b33d0ba2884c1a73c83c6ce6 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Thu, 12 Jul 2012 23:09:36 +0100 Subject: Extend "show circuits" to show circuit code, ip and viewer name. Also change to use standard table formatting "show circuits" and "show connections" console commands are very similar but access different data structures. --- OpenSim/Framework/AgentCircuitData.cs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 57fb808..ffcc584 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -99,6 +99,11 @@ namespace OpenSim.Framework public string lastname; /// + /// Agent's full name. + /// + public string Name { get { return string.Format("{0} {1}", firstname, lastname); } } + + /// /// Random Unique GUID for this session. Client gets this at login and it's /// only supposed to be disclosed over secure channels /// -- cgit v1.1 From 9ba5a7e190497be05a4e1f54ba3140366750277a Mon Sep 17 00:00:00 2001 From: Latif Khalifa Date: Sun, 17 Nov 2013 13:43:05 +0100 Subject: Normalize viewer version string to accomodate new style version reporting in the viewers --- OpenSim/Framework/AgentCircuitData.cs | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index ffcc584..acf925a 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -128,7 +128,30 @@ namespace OpenSim.Framework /// /// Viewer's version string as reported by the viewer at login /// - public string Viewer; + private string ViewerInternal; + + /// + /// Viewer's version string + /// + public string Viewer + { + set { ViewerInternal = value; } + // Try to return consistent viewer string taking into account + // that viewers have chaagned how version is reported + // See http://opensimulator.org/mantis/view.php?id=6851 + get + { + // Old style version string contains viewer name followed by a space followed by a version number + if (ViewerInternal.Contains(" ")) + { + return ViewerInternal; + } + else // New style version contains no spaces, just version number + { + return Channel + " " + ViewerInternal; + } + } + } /// /// The channel strinf sent by the viewer at login -- cgit v1.1 From b71952df49784167a4c2eed218424064b90bfd63 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Tue, 19 Nov 2013 23:36:44 +0000 Subject: Stop AgentCircuitData.Viewer.get() from throwing an error if no Viewer has been set. Continue to return null instead. --- OpenSim/Framework/AgentCircuitData.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index acf925a..51f0a1e 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -142,7 +142,7 @@ namespace OpenSim.Framework get { // Old style version string contains viewer name followed by a space followed by a version number - if (ViewerInternal.Contains(" ")) + if (ViewerInternal == null || ViewerInternal.Contains(" ")) { return ViewerInternal; } -- cgit v1.1 From f9984a9685ac92a34272f7231a0ec4097fc31a79 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Tue, 19 Nov 2013 23:39:52 +0000 Subject: rename private field ACD.ViewerInternal to m_viewerInternal in line with conventions used elsewhere in code --- OpenSim/Framework/AgentCircuitData.cs | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index 51f0a1e..f2fe494 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -128,27 +128,28 @@ namespace OpenSim.Framework /// /// Viewer's version string as reported by the viewer at login /// - private string ViewerInternal; + private string m_viewerInternal; /// /// Viewer's version string /// public string Viewer { - set { ViewerInternal = value; } + set { m_viewerInternal = value; } + // Try to return consistent viewer string taking into account // that viewers have chaagned how version is reported // See http://opensimulator.org/mantis/view.php?id=6851 get { // Old style version string contains viewer name followed by a space followed by a version number - if (ViewerInternal == null || ViewerInternal.Contains(" ")) + if (m_viewerInternal == null || m_viewerInternal.Contains(" ")) { - return ViewerInternal; + return m_viewerInternal; } else // New style version contains no spaces, just version number { - return Channel + " " + ViewerInternal; + return Channel + " " + m_viewerInternal; } } } -- cgit v1.1 From 251b93d97eb6d8d56c4deb1f6f56dbe2092c2976 Mon Sep 17 00:00:00 2001 From: Oren Hurvitz Date: Wed, 21 May 2014 19:05:20 +0300 Subject: Store the Teleport Flags in the Circuit. This doesn't seem to be necessary, because everything has worked so far, but it's the right thing to do. --- OpenSim/Framework/AgentCircuitData.cs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'OpenSim/Framework/AgentCircuitData.cs') diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index f2fe494..0d053e4 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -321,6 +321,8 @@ namespace OpenSim.Framework Mac = args["mac"].AsString(); if (args["id0"] != null) Id0 = args["id0"].AsString(); + if (args["teleport_flags"] != null) + teleportFlags = args["teleport_flags"].AsUInteger(); if (args["start_pos"] != null) Vector3.TryParse(args["start_pos"].AsString(), out startpos); -- cgit v1.1