From 00800c59d35662d65aeb61a17de0d56fa6196509 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Fri, 12 Feb 2010 23:13:35 +0000 Subject: 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. --- OpenSim/Region/Application/OpenSim.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'OpenSim/Region/Application') diff --git a/OpenSim/Region/Application/OpenSim.cs b/OpenSim/Region/Application/OpenSim.cs index eccd276..a86a831 100755 --- a/OpenSim/Region/Application/OpenSim.cs +++ b/OpenSim/Region/Application/OpenSim.cs @@ -1183,14 +1183,14 @@ namespace OpenSim } if (cmdparams.Length > 4) { - loadOffset.X = (float) Convert.ToDecimal(cmdparams[4]); + loadOffset.X = (float)Convert.ToDecimal(cmdparams[4], Culture.NumberFormatInfo); if (cmdparams.Length > 5) { - loadOffset.Y = (float) Convert.ToDecimal(cmdparams[5]); + loadOffset.Y = (float)Convert.ToDecimal(cmdparams[5], Culture.NumberFormatInfo); } if (cmdparams.Length > 6) { - loadOffset.Z = (float) Convert.ToDecimal(cmdparams[6]); + loadOffset.Z = (float)Convert.ToDecimal(cmdparams[6], Culture.NumberFormatInfo); } MainConsole.Instance.Output(String.Format("loadOffsets = <{0},{1},{2}>",loadOffset.X,loadOffset.Y,loadOffset.Z)); } -- cgit v1.1