aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
authorSHsuperCM <shsupercm@gmail.com>2022-01-17 05:07:02 +0200
committerSHsuperCM <shsupercm@gmail.com>2022-01-17 05:07:02 +0200
commit28018521d2ee7d6217b28395f01d594ff37c1191 (patch)
treec1eaf42e2332886f0287b2dfefaeb33187b4be90 /src/main/java
parentf1cec6b7ef6baa980ffc626b1327440d290906e6 (diff)
downloadCITResewn-28018521d2ee7d6217b28395f01d594ff37c1191.tar.gz
CITResewn-28018521d2ee7d6217b28395f01d594ff37c1191.tar.bz2
CITResewn-28018521d2ee7d6217b28395f01d594ff37c1191.zip
Fixed properties not reading UTF characters
Fixes #95
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/shcm/shsupercm/fabric/citresewn/pack/CITParser.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/shcm/shsupercm/fabric/citresewn/pack/CITParser.java b/src/main/java/shcm/shsupercm/fabric/citresewn/pack/CITParser.java
index 2872c48..974d2ec 100644
--- a/src/main/java/shcm/shsupercm/fabric/citresewn/pack/CITParser.java
+++ b/src/main/java/shcm/shsupercm/fabric/citresewn/pack/CITParser.java
@@ -11,6 +11,8 @@ import shcm.shsupercm.fabric.citresewn.mixin.core.GroupResourcePackAccessor;
import shcm.shsupercm.fabric.citresewn.pack.cits.*;
import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.nio.charset.StandardCharsets;
import java.util.*;
import java.util.stream.Collectors;
import java.util.stream.Stream;
@@ -89,7 +91,7 @@ public final class CITParser { private CITParser() {}
.flatMap(citIdentifier -> {
try (InputStream is = resourcePack.open(ResourceType.CLIENT_RESOURCES, citIdentifier)) {
Properties citProperties = new Properties();
- citProperties.load(is);
+ citProperties.load(new InputStreamReader(is, StandardCharsets.UTF_8));
CITConstructor type = REGISTRY.get(citProperties.getProperty("type", "item"));
if (type == null)