From 1f6fa627841a146f182b53c39187ead4f39a6372 Mon Sep 17 00:00:00 2001 From: colinator27 <17358554+colinator27@users.noreply.github.com> Date: Sat, 17 Aug 2024 12:49:23 -0400 Subject: [PATCH] Fix EmSize being always parsed as 0, if a float --- UndertaleModLib/Models/UndertaleFont.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UndertaleModLib/Models/UndertaleFont.cs b/UndertaleModLib/Models/UndertaleFont.cs index 34a495aff..e8d5a57d2 100644 --- a/UndertaleModLib/Models/UndertaleFont.cs +++ b/UndertaleModLib/Models/UndertaleFont.cs @@ -313,7 +313,7 @@ public void Unserialize(UndertaleReader reader) // since the float is always written negated, it has the first bit set. if ((readEmSize & (1 << 31)) != 0) { - float fsize = -BitConverter.ToSingle(BitConverter.GetBytes(EmSize), 0); + float fsize = -BitConverter.ToSingle(BitConverter.GetBytes(readEmSize), 0); EmSize = fsize; EmSizeIsFloat = true; }