From 8d410eb70543cfff1004b9a54cd65d5bcae40bdd Mon Sep 17 00:00:00 2001 From: Nestorboy <35258953+Nestorboy@users.noreply.github.com> Date: Tue, 10 Sep 2024 01:59:29 +0200 Subject: [PATCH] Fixed certain cultures crashing the app --- EasyXnb/GeneratorGame.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/EasyXnb/GeneratorGame.cs b/EasyXnb/GeneratorGame.cs index 6e0d17f..16b1c46 100644 --- a/EasyXnb/GeneratorGame.cs +++ b/EasyXnb/GeneratorGame.cs @@ -12,6 +12,7 @@ using Microsoft.Xna.Framework.Graphics; using System.Configuration; using System.Collections.Specialized; +using System.Globalization; //untested: //texture loading in-game @@ -126,7 +127,7 @@ public GeneratorGame() closeImmediatelySetting = bool.Parse(ConfigurationManager.AppSettings.Get("CloseImmediately")); waitForInputOnErrorSetting = bool.Parse(ConfigurationManager.AppSettings.Get("WaitForInputOnError")); - modelScale = float.Parse(ConfigurationManager.AppSettings.Get("ModelScale")); + modelScale = float.Parse(ConfigurationManager.AppSettings.Get("ModelScale"), CultureInfo.InvariantCulture); modelSwapWindingOrder = bool.Parse(ConfigurationManager.AppSettings.Get("ModelSwapWindingOrder")); modelGenerateTangentFrames = bool.Parse(ConfigurationManager.AppSettings.Get("ModelGenerateTangentFrames"));