Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-11-08 17:20:24 +01:00
Merge pull request #1633 from KennyTV/abstraction
Put translation values into correct map
Dieser Commit ist enthalten in:
Commit
c9abd745c5
@ -77,14 +77,16 @@ public class MappingData {
|
||||
}
|
||||
for (String line : lines) {
|
||||
if (line.isEmpty()) continue;
|
||||
|
||||
String[] keyAndTranslation = line.split("=", 2);
|
||||
if (keyAndTranslation.length != 2) continue;
|
||||
|
||||
String key = keyAndTranslation[0];
|
||||
String translation = keyAndTranslation[1].replaceAll("%(\\d\\$)?d", "%$1s");
|
||||
if (!translateData.containsKey(key)) {
|
||||
translateMapping.put(key, translation);
|
||||
String translation = keyAndTranslation[1].replaceAll("%(\\d\\$)?d", "%$1s");
|
||||
mojangTranslation.put(key, translation);
|
||||
} else {
|
||||
String dataValue = translateData.get(keyAndTranslation[0]);
|
||||
String dataValue = translateData.get(key);
|
||||
if (dataValue != null) {
|
||||
translateMapping.put(key, dataValue);
|
||||
}
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren