summaryrefslogtreecommitdiff
blob: 9bea3ee7fb9893abe48432eacd2b408f2f369fba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Date: Sun Jul  1 00:34:03 UTC 2012
Subject: https://github.com/OpenRA/OpenRA/issues/2005

fixed in https://github.com/OpenRA/OpenRA/commit/c068be453a9bcb7bc1fdd5874dc1296b6f4810d0#diff-0

--- OpenRA.FileFormats/FieldLoader.cs
+++ OpenRA.FileFormats/FieldLoader.cs
@@ -325,6 +325,10 @@
 					((int)c.B).Clamp(0, 255));
 			}
 
+			// Don't save floats in settings.yaml using country-specific decimal separators which can be misunderstood as group seperators.
+			if (t == typeof(float))
+				return ((float)v).ToString(CultureInfo.InvariantCulture);
+
 			if (t == typeof(Rectangle))
 			{
 				var r = (Rectangle)v;