aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Grid/UserServer.Modules/UserManager.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2010-02-12 23:13:35 +0000
committerJustin Clark-Casey (justincc)2010-02-12 23:13:35 +0000
commit00800c59d35662d65aeb61a17de0d56fa6196509 (patch)
tree594c2eefcf1806392d6c00cb86cf3b764f1d9f1c /OpenSim/Grid/UserServer.Modules/UserManager.cs
parentminor: remove completely commented out and unused class (diff)
downloadopensim-SC_OLD-00800c59d35662d65aeb61a17de0d56fa6196509.zip
opensim-SC_OLD-00800c59d35662d65aeb61a17de0d56fa6196509.tar.gz
opensim-SC_OLD-00800c59d35662d65aeb61a17de0d56fa6196509.tar.bz2
opensim-SC_OLD-00800c59d35662d65aeb61a17de0d56fa6196509.tar.xz
Apply last two patches from http://opensimulator.org/mantis/view.php?id=3522
These patch should allow people using systems that do not have their locale set to En_US or similar to use OpenSim without suffering effects such as being a million miles up in the air on login. The problem was caused by parsing strings without forcing that parse to be En_US (hence different decimal and digit group symbols were causing problems). Thanks very much to VikingErik for doing the legwork on this fix and phacelia for spotting it in the first place.
Diffstat (limited to 'OpenSim/Grid/UserServer.Modules/UserManager.cs')
-rw-r--r--OpenSim/Grid/UserServer.Modules/UserManager.cs24
1 files changed, 12 insertions, 12 deletions
diff --git a/OpenSim/Grid/UserServer.Modules/UserManager.cs b/OpenSim/Grid/UserServer.Modules/UserManager.cs
index 36c6297..a2032dc 100644
--- a/OpenSim/Grid/UserServer.Modules/UserManager.cs
+++ b/OpenSim/Grid/UserServer.Modules/UserManager.cs
@@ -503,7 +503,7 @@ namespace OpenSim.Grid.UserServer.Modules
503 { 503 {
504 try 504 try
505 { 505 {
506 userProfile.HomeLocationX = (float)Convert.ToDecimal((string)requestData["home_pos_x"]); 506 userProfile.HomeLocationX = (float)Convert.ToDecimal((string)requestData["home_pos_x"], Culture.NumberFormatInfo);
507 } 507 }
508 catch (InvalidCastException) 508 catch (InvalidCastException)
509 { 509 {
@@ -514,7 +514,7 @@ namespace OpenSim.Grid.UserServer.Modules
514 { 514 {
515 try 515 try
516 { 516 {
517 userProfile.HomeLocationY = (float)Convert.ToDecimal((string)requestData["home_pos_y"]); 517 userProfile.HomeLocationY = (float)Convert.ToDecimal((string)requestData["home_pos_y"], Culture.NumberFormatInfo);
518 } 518 }
519 catch (InvalidCastException) 519 catch (InvalidCastException)
520 { 520 {
@@ -525,7 +525,7 @@ namespace OpenSim.Grid.UserServer.Modules
525 { 525 {
526 try 526 try
527 { 527 {
528 userProfile.HomeLocationZ = (float)Convert.ToDecimal((string)requestData["home_pos_z"]); 528 userProfile.HomeLocationZ = (float)Convert.ToDecimal((string)requestData["home_pos_z"], Culture.NumberFormatInfo);
529 } 529 }
530 catch (InvalidCastException) 530 catch (InvalidCastException)
531 { 531 {
@@ -536,7 +536,7 @@ namespace OpenSim.Grid.UserServer.Modules
536 { 536 {
537 try 537 try
538 { 538 {
539 userProfile.HomeLookAtX = (float)Convert.ToDecimal((string)requestData["home_look_x"]); 539 userProfile.HomeLookAtX = (float)Convert.ToDecimal((string)requestData["home_look_x"], Culture.NumberFormatInfo);
540 } 540 }
541 catch (InvalidCastException) 541 catch (InvalidCastException)
542 { 542 {
@@ -547,7 +547,7 @@ namespace OpenSim.Grid.UserServer.Modules
547 { 547 {
548 try 548 try
549 { 549 {
550 userProfile.HomeLookAtY = (float)Convert.ToDecimal((string)requestData["home_look_y"]); 550 userProfile.HomeLookAtY = (float)Convert.ToDecimal((string)requestData["home_look_y"], Culture.NumberFormatInfo);
551 } 551 }
552 catch (InvalidCastException) 552 catch (InvalidCastException)
553 { 553 {
@@ -558,7 +558,7 @@ namespace OpenSim.Grid.UserServer.Modules
558 { 558 {
559 try 559 try
560 { 560 {
561 userProfile.HomeLookAtZ = (float)Convert.ToDecimal((string)requestData["home_look_z"]); 561 userProfile.HomeLookAtZ = (float)Convert.ToDecimal((string)requestData["home_look_z"], Culture.NumberFormatInfo);
562 } 562 }
563 catch (InvalidCastException) 563 catch (InvalidCastException)
564 { 564 {
@@ -634,13 +634,13 @@ namespace OpenSim.Grid.UserServer.Modules
634 UUID RegionID = new UUID((string)requestData["region_uuid"]); 634 UUID RegionID = new UUID((string)requestData["region_uuid"]);
635 ulong regionhandle = (ulong)Convert.ToInt64((string)requestData["region_handle"]); 635 ulong regionhandle = (ulong)Convert.ToInt64((string)requestData["region_handle"]);
636 Vector3 position = new Vector3( 636 Vector3 position = new Vector3(
637 (float)Convert.ToDecimal((string)requestData["region_pos_x"]), 637 (float)Convert.ToDecimal((string)requestData["region_pos_x"], Culture.NumberFormatInfo),
638 (float)Convert.ToDecimal((string)requestData["region_pos_y"]), 638 (float)Convert.ToDecimal((string)requestData["region_pos_y"], Culture.NumberFormatInfo),
639 (float)Convert.ToDecimal((string)requestData["region_pos_z"])); 639 (float)Convert.ToDecimal((string)requestData["region_pos_z"], Culture.NumberFormatInfo));
640 Vector3 lookat = new Vector3( 640 Vector3 lookat = new Vector3(
641 (float)Convert.ToDecimal((string)requestData["lookat_x"]), 641 (float)Convert.ToDecimal((string)requestData["lookat_x"], Culture.NumberFormatInfo),
642 (float)Convert.ToDecimal((string)requestData["lookat_y"]), 642 (float)Convert.ToDecimal((string)requestData["lookat_y"], Culture.NumberFormatInfo),
643 (float)Convert.ToDecimal((string)requestData["lookat_z"])); 643 (float)Convert.ToDecimal((string)requestData["lookat_z"], Culture.NumberFormatInfo));
644 644
645 handlerLogOffUser = OnLogOffUser; 645 handlerLogOffUser = OnLogOffUser;
646 if (handlerLogOffUser != null) 646 if (handlerLogOffUser != null)