aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services/LLLoginService/LLLoginResponse.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Services/LLLoginService/LLLoginResponse.cs')
-rw-r--r--OpenSim/Services/LLLoginService/LLLoginResponse.cs35
1 files changed, 29 insertions, 6 deletions
diff --git a/OpenSim/Services/LLLoginService/LLLoginResponse.cs b/OpenSim/Services/LLLoginService/LLLoginResponse.cs
index 6ab5258..6a0a799 100644
--- a/OpenSim/Services/LLLoginService/LLLoginResponse.cs
+++ b/OpenSim/Services/LLLoginService/LLLoginResponse.cs
@@ -254,11 +254,12 @@ namespace OpenSim.Services.LLLoginService
254 Currency = currency; 254 Currency = currency;
255 ClassifiedFee = classifiedFee; 255 ClassifiedFee = classifiedFee;
256 256
257
258 FillOutHomeData(pinfo, home); 257 FillOutHomeData(pinfo, home);
259 LookAt = String.Format("[r{0},r{1},r{2}]", lookAt.X, lookAt.Y, lookAt.Z); 258 LookAt = String.Format("[r{0},r{1},r{2}]", lookAt.X, lookAt.Y, lookAt.Z);
260 259
261 FillOutRegionData(destination); 260 FillOutRegionData(destination);
261 m_log.DebugFormat("[LOGIN RESPONSE] LLLoginResponse create. sizeX={0}, sizeY={1}", RegionSizeX, RegionSizeY);
262 Util.PrintCallStack();
262 263
263 FillOutSeedCap(aCircuit, destination, clientIP); 264 FillOutSeedCap(aCircuit, destination, clientIP);
264 265
@@ -361,7 +362,8 @@ namespace OpenSim.Services.LLLoginService
361 362
362 private void FillOutHomeData(GridUserInfo pinfo, GridRegion home) 363 private void FillOutHomeData(GridUserInfo pinfo, GridRegion home)
363 { 364 {
364 int x = 1000 * (int)Constants.RegionSize, y = 1000 * (int)Constants.RegionSize; 365 int x = (int)Util.RegionToWorldLoc(1000);
366 int y = (int)Util.RegionToWorldLoc(1000);
365 if (home != null) 367 if (home != null)
366 { 368 {
367 x = home.RegionLocX; 369 x = home.RegionLocX;
@@ -384,6 +386,8 @@ namespace OpenSim.Services.LLLoginService
384 SimPort = (uint)endPoint.Port; 386 SimPort = (uint)endPoint.Port;
385 RegionX = (uint)destination.RegionLocX; 387 RegionX = (uint)destination.RegionLocX;
386 RegionY = (uint)destination.RegionLocY; 388 RegionY = (uint)destination.RegionLocY;
389 RegionSizeX = destination.RegionSizeX;
390 RegionSizeY = destination.RegionSizeY;
387 } 391 }
388 392
389 private void FillOutSeedCap(AgentCircuitData aCircuit, GridRegion destination, IPEndPoint ipepClient) 393 private void FillOutSeedCap(AgentCircuitData aCircuit, GridRegion destination, IPEndPoint ipepClient)
@@ -433,10 +437,23 @@ namespace OpenSim.Services.LLLoginService
433 ErrorReason = "key"; 437 ErrorReason = "key";
434 welcomeMessage = "Welcome to OpenSim!"; 438 welcomeMessage = "Welcome to OpenSim!";
435 seedCapability = String.Empty; 439 seedCapability = String.Empty;
436 home = "{'region_handle':[r" + (1000*Constants.RegionSize).ToString() + ",r" + (1000*Constants.RegionSize).ToString() + "], 'position':[r" + 440 home = "{'region_handle':["
437 userProfile.homepos.X.ToString() + ",r" + userProfile.homepos.Y.ToString() + ",r" + 441 + "r" + Util.RegionToWorldLoc(1000).ToString()
438 userProfile.homepos.Z.ToString() + "], 'look_at':[r" + userProfile.homelookat.X.ToString() + ",r" + 442 + ","
439 userProfile.homelookat.Y.ToString() + ",r" + userProfile.homelookat.Z.ToString() + "]}"; 443 + "r" + Util.RegionToWorldLoc(1000).ToString()
444 + "], 'position':["
445 + "r" + userProfile.homepos.X.ToString()
446 + ","
447 + "r" + userProfile.homepos.Y.ToString()
448 + ","
449 + "r" + userProfile.homepos.Z.ToString()
450 + "], 'look_at':["
451 + "r" + userProfile.homelookat.X.ToString()
452 + ","
453 + "r" + userProfile.homelookat.Y.ToString()
454 + ","
455 + "r" + userProfile.homelookat.Z.ToString()
456 + "]}";
440 lookAt = "[r0.99949799999999999756,r0.03166859999999999814,r0]"; 457 lookAt = "[r0.99949799999999999756,r0.03166859999999999814,r0]";
441 RegionX = (uint) 255232; 458 RegionX = (uint) 255232;
442 RegionY = (uint) 254976; 459 RegionY = (uint) 254976;
@@ -529,6 +546,9 @@ namespace OpenSim.Services.LLLoginService
529 responseData["message"] = welcomeMessage; 546 responseData["message"] = welcomeMessage;
530 responseData["region_x"] = (Int32)(RegionX); 547 responseData["region_x"] = (Int32)(RegionX);
531 responseData["region_y"] = (Int32)(RegionY); 548 responseData["region_y"] = (Int32)(RegionY);
549 responseData["region_size_x"] = (Int32)RegionSizeX;
550 responseData["region_size_y"] = (Int32)RegionSizeY;
551 m_log.DebugFormat("[LOGIN RESPONSE] returning sizeX={0}, sizeY={1}", RegionSizeX, RegionSizeY);
532 552
533 if (searchURL != String.Empty) 553 if (searchURL != String.Empty)
534 responseData["search"] = searchURL; 554 responseData["search"] = searchURL;
@@ -918,6 +938,9 @@ namespace OpenSim.Services.LLLoginService
918 set { regionY = value; } 938 set { regionY = value; }
919 } 939 }
920 940
941 public int RegionSizeX { get; private set; }
942 public int RegionSizeY { get; private set; }
943
921 public string SunTexture 944 public string SunTexture
922 { 945 {
923 get { return sunTexture; } 946 get { return sunTexture; }