diff --git a/Ultima/Helpers/TileDataHelpers.cs b/Ultima/Helpers/TileDataHelpers.cs index 5bcfc71..9e5eae5 100644 --- a/Ultima/Helpers/TileDataHelpers.cs +++ b/Ultima/Helpers/TileDataHelpers.cs @@ -26,7 +26,7 @@ public static unsafe string ReadNameString(byte* buffer) _stringBuffer[count] = *buffer++; } - return Encoding.ASCII.GetString(_stringBuffer, 0, count); + return Encoding.UTF8.GetString(_stringBuffer, 0, count); } public static string ReadNameString(byte[] buffer, int len) @@ -38,7 +38,7 @@ public static string ReadNameString(byte[] buffer, int len) //; } - return Encoding.ASCII.GetString(buffer, 0, count); + return Encoding.UTF8.GetString(buffer, 0, count); } public static int ConvertStringToInt(string text) diff --git a/Ultima/TileData.cs b/Ultima/TileData.cs index 39c3c1f..91f0c6d 100644 --- a/Ultima/TileData.cs +++ b/Ultima/TileData.cs @@ -1419,7 +1419,7 @@ public static void SaveTileData(string fileName) var b = new byte[20]; if (LandTable[i].Name != null) { - byte[] bb = Encoding.ASCII.GetBytes(LandTable[i].Name); + byte[] bb = Encoding.UTF8.GetBytes(LandTable[i].Name); if (bb.Length > 20) { Array.Resize(ref bb, 20); @@ -1464,7 +1464,7 @@ public static void SaveTileData(string fileName) var b = new byte[20]; if (ItemTable[i].Name != null) { - byte[] bb = Encoding.ASCII.GetBytes(ItemTable[i].Name); + byte[] bb = Encoding.UTF8.GetBytes(ItemTable[i].Name); if (bb.Length > 20) { Array.Resize(ref bb, 20);