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