Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-27 08:30:09 +01:00
19w08a metadata changes
Dieser Commit ist enthalten in:
Ursprung
3de06c269d
Commit
ab5eb2c7ef
@ -32,20 +32,38 @@ public class MetadataRewriter {
|
|||||||
|
|
||||||
if (type == null) continue;
|
if (type == null) continue;
|
||||||
|
|
||||||
if (type.isOrHasParent(Entity1_14Types.EntityType.MINECART_ABSTRACT) && metadata.getId() == 9) {
|
//Metadata 6 added to abstract_entity
|
||||||
|
if (metadata.getId() > 5) {
|
||||||
|
metadata.setId(metadata.getId() + 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
//Metadata 12 added to living_entity
|
||||||
|
if (metadata.getId() > 11 && type.isOrHasParent(Entity1_14Types.EntityType.LIVINGENTITY)) {
|
||||||
|
metadata.setId(metadata.getId() + 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (type.isOrHasParent(Entity1_14Types.EntityType.MINECART_ABSTRACT)) {
|
||||||
|
if (metadata.getId() == 10) {
|
||||||
// New block format
|
// New block format
|
||||||
int data = (int) metadata.getValue();
|
int data = (int) metadata.getValue();
|
||||||
metadata.setValue(Protocol1_14To1_13_2.getNewBlockStateId(data));
|
metadata.setValue(Protocol1_14To1_13_2.getNewBlockStateId(data));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (type.is(Entity1_14Types.EntityType.HORSE)) {
|
||||||
|
if (metadata.getId() == 18) {
|
||||||
|
metadatas.remove(metadata); //TODO Probably sent as entity equipment now
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (type.is(Entity1_14Types.EntityType.VILLAGER)) {
|
if (type.is(Entity1_14Types.EntityType.VILLAGER)) {
|
||||||
if (metadata.getId() == 13) {
|
if (metadata.getId() == 15) {
|
||||||
// plains
|
// plains
|
||||||
metadata.setValue(new VillagerData(2, getNewProfessionId((int) metadata.getValue()), 0));
|
metadata.setValue(new VillagerData(2, getNewProfessionId((int) metadata.getValue()), 0));
|
||||||
metadata.setMetaType(MetaType1_14.VillagerData);
|
metadata.setMetaType(MetaType1_14.VillagerData);
|
||||||
}
|
}
|
||||||
} else if (type.is(Entity1_14Types.EntityType.ZOMBIE_VILLAGER)) {
|
} else if (type.is(Entity1_14Types.EntityType.ZOMBIE_VILLAGER)) {
|
||||||
if (metadata.getId() == 17) {
|
if (metadata.getId() == 19) {
|
||||||
// plains
|
// plains
|
||||||
metadata.setValue(new VillagerData(2, getNewProfessionId((int) metadata.getValue()), 0));
|
metadata.setValue(new VillagerData(2, getNewProfessionId((int) metadata.getValue()), 0));
|
||||||
metadata.setMetaType(MetaType1_14.VillagerData);
|
metadata.setMetaType(MetaType1_14.VillagerData);
|
||||||
@ -53,13 +71,13 @@ public class MetadataRewriter {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (type.isOrHasParent(Entity1_14Types.EntityType.ARROW)) {
|
if (type.isOrHasParent(Entity1_14Types.EntityType.ARROW)) {
|
||||||
if (metadata.getId() >= 8) {
|
if (metadata.getId() >= 9) {
|
||||||
metadata.setId(metadata.getId() + 1);
|
metadata.setId(metadata.getId() + 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (type.is(Entity1_14Types.EntityType.FIREWORKS_ROCKET)) {
|
if (type.is(Entity1_14Types.EntityType.FIREWORKS_ROCKET)) {
|
||||||
if (metadata.getId() == 7) {
|
if (metadata.getId() == 8) {
|
||||||
if (metadata.getValue().equals(0)) metadata.setValue(null); // https://bugs.mojang.com/browse/MC-111480
|
if (metadata.getValue().equals(0)) metadata.setValue(null); // https://bugs.mojang.com/browse/MC-111480
|
||||||
metadata.setMetaType(MetaType1_14.OptVarInt);
|
metadata.setMetaType(MetaType1_14.OptVarInt);
|
||||||
}
|
}
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren