Fix mushrooms blocks on 1.12.2 and below (#351)

This commit is contained in:
MrMicky 2021-04-03 10:15:51 +02:00 committed by GitHub
parent 0812204f11
commit 7a5e57e1a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -106,6 +106,25 @@ public class BackwardsMappings extends nl.matsv.viabackwards.api.data.BackwardsM
}
}
@Override
public int getNewBlockStateId(int id) {
int mappedId = super.getNewBlockStateId(id);
// https://github.com/ViaVersion/ViaBackwards/issues/290
switch (mappedId) {
case 1595:
case 1596:
case 1597:
return 1584; // brown mushroom block
case 1611:
case 1612:
case 1613:
return 1600; // red mushroom block
default:
return mappedId;
}
}
@Override
protected int checkValidity(int id, int mappedId, String type) {
// Don't warn for missing ids here