Merge pull request #1375 from KennyTV/master

Fix 1.13 clients unable to break infested blocks (#1370)
This commit is contained in:
Myles 2019-06-24 20:37:08 +01:00 committed by GitHub
commit b675018acf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -55,7 +55,8 @@ public class MappingData {
MappingData.class.getClassLoader()
.getResourceAsStream("assets/viaversion/data/mapping-lang-1.12-1.13.json")
),
(new TypeToken<Map<String, String>>(){}).getType());
(new TypeToken<Map<String, String>>() {
}).getType());
try {
String[] lines;
try (Reader reader = new InputStreamReader(MappingData.class.getClassLoader()
@ -199,6 +200,14 @@ public class MappingData {
if (Via.getConfig().isSnowCollisionFix()) {
oldToNew[1248] = 3416;
}
// Remap infested blocks, as they are instantly breakabale in 1.13+ and can't be broken by those clients on older servers
oldToNew[1552] = 1; // stone
oldToNew[1553] = 14; // cobblestone
oldToNew[1554] = 3983; // stone bricks
oldToNew[1555] = 3984; // mossy stone bricks
oldToNew[1556] = 3985; // cracked stone bricks
oldToNew[1557] = 3986; // chiseled stone bricks
}
@Override