Metadata change voor illagers (Should be changed @ wiki.vg)

This commit is contained in:
Matsv 2017-06-08 19:35:26 +02:00
parent 5a4dd8bb6a
commit d113e11c3b
No known key found for this signature in database
GPG Key ID: 97CEC2A2EA31350F
3 changed files with 8 additions and 3 deletions

View File

@ -69,10 +69,11 @@ public class EntityType1_12 {
ENTITY_HUMAN(-1, ENTITY_LIVING),
ARMOR_STAND(30, ENTITY_LIVING),
EVOCATION_ILLAGER(34, ENTITY_INSENTIENT),
ENTITY_ILLAGER_ABSTRACT(-1, ENTITY_INSENTIENT),
EVOCATION_ILLAGER(34, ENTITY_ILLAGER_ABSTRACT),
VEX(35, ENTITY_INSENTIENT),
VINDICATION_ILLAGER(36, ENTITY_INSENTIENT),
ILLUSION_ILLAGER(37, EVOCATION_ILLAGER),
ILLUSION_ILLAGER(37, ENTITY_ILLAGER_ABSTRACT),
// Vehicles
MINECART_ABSTRACT(-1, ENTITY),

View File

@ -460,7 +460,7 @@ public class EntityPackets extends EntityRewriter<Protocol1_10To1_11> {
data.setId(13);
data.setMetaType(MetaType1_9.VarInt);
data.setValue((byte) data.getValue() == 1 ? 2 : 4);
data.setValue((int) data.getValue() == 1 ? 2 : 4);
return data;
});

View File

@ -344,6 +344,10 @@ public class EntityPackets1_12 extends EntityRewriter<Protocol1_11_1To1_12> {
regEntType(EntityType.PARROT, EntityType.BAT).spawnMetadata(storage -> storage.add(new Metadata(12, MetaType1_12.Byte, (byte) 0x00)));
regEntType(EntityType.ILLUSION_ILLAGER, EntityType.EVOCATION_ILLAGER);
// Handle Illager TODO wtf does this metadata do?
registerMetaHandler().filter(EntityType.ENTITY_ILLAGER_ABSTRACT, true, 12).removed();
registerMetaHandler().filter(EntityType.ENTITY_ILLAGER_ABSTRACT, true, 13).handleIndexChange(12);
// Parrot remove animal metadata
registerMetaHandler().filter(EntityType.PARROT, 12).removed(); // Is baby
registerMetaHandler().filter(EntityType.PARROT, 13).removed(); // Flags (Is sitting etc, might be useful in the future (bat inactive TODO do more research about this entity)