Skip to content

Commit 6c59171

Browse files
committed
Don't use ExEncoding for hunter/palico name
See Fusion86/MHWAppearanceEditor#13
1 parent 2a7e204 commit 6c59171

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Cirilla.Core/Cirilla.Core.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<PropertyGroup>
44
<TargetFramework>netstandard2.0</TargetFramework>
5-
<Version>0.8.1</Version>
5+
<Version>0.8.2</Version>
66
<Authors>Fusion86</Authors>
77
<Company />
88
</PropertyGroup>

Cirilla.Core/Models/SaveData.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -212,13 +212,13 @@ public object Clone()
212212

213213
public string HunterName
214214
{
215-
get => ExEncoding.UTF8.GetString(_native.HunterName).TrimEnd('\0');
215+
get => Encoding.UTF8.GetString(_native.HunterName).TrimEnd('\0');
216216

217217
set
218218
{
219219
// Not sure if it is needed to make the array exactly 64 bytes large
220220
byte[] bytes = new byte[64];
221-
byte[] cStr = ExEncoding.UTF8.GetBytes(value);
221+
byte[] cStr = Encoding.UTF8.GetBytes(value);
222222

223223
if (cStr.Length > 64)
224224
throw new Exception("Hunter name can't use more than 64 bytes, try using a shorter name!");
@@ -230,13 +230,13 @@ public string HunterName
230230

231231
public string PalicoName
232232
{
233-
get => ExEncoding.UTF8.GetString(_native.PalicoName).TrimEnd('\0');
233+
get => Encoding.UTF8.GetString(_native.PalicoName).TrimEnd('\0');
234234

235235
set
236236
{
237237
// Not sure if it is needed to make the array exactly 64 bytes large
238238
byte[] bytes = new byte[64];
239-
byte[] cStr = ExEncoding.UTF8.GetBytes(value);
239+
byte[] cStr = Encoding.UTF8.GetBytes(value);
240240

241241
if (cStr.Length > 64)
242242
throw new Exception("Palico name can't use more than 64 bytes, try using a shorter name!");

0 commit comments

Comments
 (0)