From 244bfcde5b86180981e99ac9e88eb394f20bcd09 Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Thu, 17 Apr 2008 05:07:14 +0000 Subject: * Implements 'Set Home to Here' * Implements 'Teleport Home' * User Server has to be updated for it to save your home in grid mode * home position accuracy is in int because the grid comms ExpectUser method tries to convert to Uint and crashes if it gets a float. Added a convert to decimal in ExpectUser but to avoid a breaking change with old revisions, kept the save value in int for now. Eventually it needs to be a float, but lets release another incremental version before doing that. --- OpenSim/Region/Communications/OGS1/OGS1GridServices.cs | 6 +++--- OpenSim/Region/Communications/OGS1/OGS1UserServices.cs | 10 ++++++++++ 2 files changed, 13 insertions(+), 3 deletions(-) (limited to 'OpenSim/Region/Communications/OGS1') diff --git a/OpenSim/Region/Communications/OGS1/OGS1GridServices.cs b/OpenSim/Region/Communications/OGS1/OGS1GridServices.cs index 9a7274c..1135ddd 100644 --- a/OpenSim/Region/Communications/OGS1/OGS1GridServices.cs +++ b/OpenSim/Region/Communications/OGS1/OGS1GridServices.cs @@ -579,9 +579,9 @@ namespace OpenSim.Region.Communications.OGS1 { m_log.Debug("[CONNECTION DEBUGGING]: Main agent detected"); agentData.startpos = - new LLVector3(Convert.ToUInt32(requestData["startpos_x"]), - Convert.ToUInt32(requestData["startpos_y"]), - Convert.ToUInt32(requestData["startpos_z"])); + new LLVector3((float)Convert.ToDecimal((string)requestData["startpos_x"]), + (float)Convert.ToDecimal((string)requestData["startpos_y"]), + (float)Convert.ToDecimal((string)requestData["startpos_z"])); agentData.child = false; } diff --git a/OpenSim/Region/Communications/OGS1/OGS1UserServices.cs b/OpenSim/Region/Communications/OGS1/OGS1UserServices.cs index 5873eb8..c140213 100644 --- a/OpenSim/Region/Communications/OGS1/OGS1UserServices.cs +++ b/OpenSim/Region/Communications/OGS1/OGS1UserServices.cs @@ -314,6 +314,16 @@ namespace OpenSim.Region.Communications.OGS1 param["AboutText"] = UserProfile.AboutText; param["FLAboutText"] = UserProfile.FirstLifeAboutText; //param["ProfileURL"] = UserProfile.ProfileURL.ToString(); + + param["home_region"] = UserProfile.HomeRegion.ToString(); + + param["home_pos_x"] = UserProfile.HomeLocationX.ToString(); + param["home_pos_y"] = UserProfile.HomeLocationY.ToString(); + param["home_pos_z"] = UserProfile.HomeLocationZ.ToString(); + param["home_look_x"] = UserProfile.HomeLookAtX.ToString(); + param["home_look_y"] = UserProfile.HomeLookAtY.ToString(); + param["home_look_z"] = UserProfile.HomeLookAtZ.ToString(); + IList parameters = new ArrayList(); parameters.Add(param); -- cgit v1.1