Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-11-03 14:50:30 +01:00
Handle new Zombie metatag & change reset color to 21 (as documented on wiki.vg)
Dieser Commit ist enthalten in:
Ursprung
b7ca30efe8
Commit
0ada2496de
@ -132,7 +132,7 @@ public class Entity1_13Types {
|
||||
SPIDER(68, ABSTRACT_MONSTER), // akc
|
||||
CAVE_SPIDER(6, SPIDER), // aje
|
||||
|
||||
// Zombies
|
||||
// Zombies - META CHECKED
|
||||
ZOMBIE(86, ABSTRACT_MONSTER), // aki
|
||||
DROWNED(13, ZOMBIE), // ajg
|
||||
HUSK(29, ZOMBIE), // ajp
|
||||
|
@ -35,8 +35,7 @@ public class MetadataRewriter {
|
||||
if (metadata.getMetaType() == MetaType1_13.Slot) {
|
||||
metadata.setMetaType(MetaType1_13.Slot);
|
||||
InventoryPackets.toClient((Item) metadata.getValue());
|
||||
}
|
||||
if (metadata.getMetaType() == MetaType1_13.BlockID) {
|
||||
} else if (metadata.getMetaType() == MetaType1_13.BlockID) {
|
||||
// Convert to new block id
|
||||
metadata.setValue(WorldPackets.toNewId((int) metadata.getValue()));
|
||||
}
|
||||
@ -50,6 +49,11 @@ public class MetadataRewriter {
|
||||
metadata.setValue(15 - (int) metadata.getValue());
|
||||
}
|
||||
|
||||
// Handle new zombie meta (INDEX 15 - Boolean - Zombie is shaking while enabled)
|
||||
if (type.isOrHasParent(Entity1_13Types.EntityType.ZOMBIE)) {
|
||||
if (metadata.getId() > 14)
|
||||
metadata.setId(metadata.getId() + 1);
|
||||
}
|
||||
|
||||
// Handle other changes
|
||||
if (type.is(Entity1_13Types.EntityType.AREA_EFFECT_CLOUD)) {
|
||||
|
@ -308,8 +308,8 @@ public class ProtocolSnapshotTo1_12_2 extends Protocol {
|
||||
// Handle new colors
|
||||
byte color = wrapper.read(Type.BYTE);
|
||||
|
||||
if (color == -1) // -1 is no longer active, use white instead
|
||||
wrapper.write(Type.VAR_INT, 15);
|
||||
if (color == -1) // -1 changed to 21
|
||||
wrapper.write(Type.VAR_INT, 21); // RESET
|
||||
else
|
||||
wrapper.write(Type.VAR_INT, (int) color);
|
||||
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren