From ace1e6c553fabb809843e97b586c7d2544cda215 Mon Sep 17 00:00:00 2001 From: KennyTV Date: Fri, 14 Feb 2020 17:00:24 +0100 Subject: [PATCH] 20w07a --- .../packets/EntityPackets1_16.java | 5 ++++ .../viabackwards/data/mapping-1.15to1.16.json | 24 ++++++++++++++++++- 2 files changed, 28 insertions(+), 1 deletion(-) diff --git a/core/src/main/java/nl/matsv/viabackwards/protocol/protocol1_15_2to1_16/packets/EntityPackets1_16.java b/core/src/main/java/nl/matsv/viabackwards/protocol/protocol1_15_2to1_16/packets/EntityPackets1_16.java index 77bed55f..57100d3a 100644 --- a/core/src/main/java/nl/matsv/viabackwards/protocol/protocol1_15_2to1_16/packets/EntityPackets1_16.java +++ b/core/src/main/java/nl/matsv/viabackwards/protocol/protocol1_15_2to1_16/packets/EntityPackets1_16.java @@ -69,6 +69,9 @@ public class EntityPackets1_16 extends EntityRewriter { }); mapEntity(Entity1_16Types.EntityType.HOGLIN, Entity1_16Types.EntityType.COW).jsonName("Hoglin"); + mapEntity(Entity1_16Types.EntityType.PIGLIN, Entity1_16Types.EntityType.ZOMBIE_PIGMAN).jsonName("Piglin"); + + registerMetaHandler().filter(Entity1_16Types.EntityType.PIGLIN, 16).removed(); // charging crossbow } @Override @@ -80,6 +83,8 @@ public class EntityPackets1_16 extends EntityRewriter { protected int getOldEntityId(int newId) { if (newId == Entity1_16Types.EntityType.HOGLIN.getId()) { return Entity1_15Types.EntityType.COW.getId(); + } else if (newId == Entity1_16Types.EntityType.PIGLIN.getId()) { + return Entity1_15Types.EntityType.ZOMBIE_PIGMAN.getId(); } return newId; } diff --git a/core/src/main/resources/assets/viabackwards/data/mapping-1.15to1.16.json b/core/src/main/resources/assets/viabackwards/data/mapping-1.15to1.16.json index 3f97dea8..ce34c682 100644 --- a/core/src/main/resources/assets/viabackwards/data/mapping-1.15to1.16.json +++ b/core/src/main/resources/assets/viabackwards/data/mapping-1.15to1.16.json @@ -5438,6 +5438,10 @@ "id": "minecraft:zombie_pigman_spawn_egg", "name": "1.16 Hoglin Spawn Egg" }, + "minecraft:piglin_spawn_egg": { + "id": "minecraft:zombie_pigman_spawn_egg", + "name": "1.16 Piglin Spawn Egg" + }, "minecraft:soul_fire_lantern": { "id": "minecraft:lantern", "name": "1.16 Soul Fire Lantern" @@ -5585,6 +5589,24 @@ "block.soul_soil.step": "block.sand.step", "block.soul_soil.place": "block.sand.place", "block.soul_soil.hit": "block.sand.hit", - "block.soul_soil.fall": "block.sand.fall" + "block.soul_soil.fall": "block.sand.fall", + "entity.hoglin.ambient": "entity.ravager.ambient", + "entity.hoglin.angry": "entity.zombie_pigman.angry", + "entity.hoglin.attack": "entity.ravager.attack", + "entity.hoglin.death": "entity.ravager.death", + "entity.hoglin.hurt": "entity.ravager.hurt", + "entity.hoglin.retreat": "entity.ravager.hurt", + "entity.hoglin.step": "entity.ravager.step", + "entity.piglin.admiring_item": "entity.zombie_pigman.ambient", + "entity.piglin.ambient": "entity.zombie_pigman.ambient", + "entity.piglin.angry": "entity.zombie_pigman.angry", + "entity.piglin.celebrate": "entity.pillager.celebrate", + "entity.piglin.death": "entity.zombie_pigman.death", + "entity.piglin.jealous": "entity.zombie_pigman.ambient", + "entity.piglin.hurt": "entity.zombie_pigman.hurt", + "entity.piglin.retreat": "entity.zombie_pigman.hurt", + "entity.piglin.step": "entity.zombie.step", + "entity.piglin.converted_to_zombified": "entity.husk.converted_to_zombie", + "entity.snow_golem.shear": "entity.sheep.shear" } } \ No newline at end of file