A bunch of 1.14 mappings

This commit is contained in:
KennyTV 2019-05-24 13:28:26 +02:00
parent 884113ae3c
commit 1d2f9c6d4c
2 changed files with 158 additions and 4 deletions

View File

@ -170,7 +170,7 @@ public class BlockItemPackets1_14 extends BlockItemRewriter<Protocol1_13_2To1_14
@Override @Override
public void handle(PacketWrapper wrapper) throws Exception { public void handle(PacketWrapper wrapper) throws Exception {
wrapper.write(Type.STRING, "minecraft:trader_list"); wrapper.write(Type.STRING, "minecraft:trader_list");
// wrapper.read(Type.STRING); // Remove channel // wrapper.read(Type.STRING); // Remove channel
int windowId = wrapper.read(Type.VAR_INT); int windowId = wrapper.read(Type.VAR_INT);
wrapper.write(Type.INT, windowId); wrapper.write(Type.INT, windowId);
@ -564,7 +564,41 @@ public class BlockItemPackets1_14 extends BlockItemRewriter<Protocol1_13_2To1_14
@Override @Override
protected void registerRewrites() { protected void registerRewrites() {
rewrite(108).repItem(new Item((short) 111, (byte) 1, (short) -1, getNamedTag("1.14 Cornflower")));
rewrite(109).repItem(new Item((short) 105, (byte) 1, (short) -1, getNamedTag("1.14 Lily of the Valley")));
rewrite(110).repItem(new Item((short) 100, (byte) 1, (short) -1, getNamedTag("1.14 Wither Rose")));
rewrite(614).repItem(new Item((short) 611, (byte) 1, (short) -1, getNamedTag("1.14 Bamboo")));
rewrite(857).repItem(new Item((short) 547, (byte) 1, (short) -1, getNamedTag("1.14 Suspicious Stew")));
rewrite(795).repItem(new Item((short) 793, (byte) 1, (short) -1, getNamedTag("1.14 Leather Horse Armor")));
rewrite(647).repItem(new Item((short) 635, (byte) 1, (short) -1, getNamedTag("1.14 Blue Dye")));
rewrite(648).repItem(new Item((short) 634, (byte) 1, (short) -1, getNamedTag("1.14 Brown Dye")));
rewrite(649).repItem(new Item((short) 631, (byte) 1, (short) -1, getNamedTag("1.14 Black Dye")));
rewrite(650).repItem(new Item((short) 646, (byte) 1, (short) -1, getNamedTag("1.14 White Dye")));
rewrite(505).repItem(new Item((short) 299, (byte) 1, (short) -1, getNamedTag("1.14 Scaffolding")));
rewrite(516).repItem(new Item((short) 515, (byte) 1, (short) -1, getNamedTag("1.14 Jigsaw Block")));
rewrite(517).repItem(new Item((short) 694, (byte) 1, (short) -1, getNamedTag("1.14 Composter")));
rewrite(864).repItem(new Item((short) 155, (byte) 1, (short) -1, getNamedTag("1.14 Barrel")));
rewrite(858).repItem(new Item((short) 158, (byte) 1, (short) -1, getNamedTag("1.14 Loom")));
rewrite(865).repItem(new Item((short) 160, (byte) 1, (short) -1, getNamedTag("1.14 Smoker")));
rewrite(866).repItem(new Item((short) 160, (byte) 1, (short) -1, getNamedTag("1.14 Blast Furnace")));
rewrite(867).repItem(new Item((short) 158, (byte) 1, (short) -1, getNamedTag("1.14 Cartography Table")));
rewrite(868).repItem(new Item((short) 158, (byte) 1, (short) -1, getNamedTag("1.14 Fletching Table")));
rewrite(869).repItem(new Item((short) 265, (byte) 1, (short) -1, getNamedTag("1.14 Grindstone")));
rewrite(870).repItem(new Item((short) 143, (byte) 1, (short) -1, getNamedTag("1.14 Lectern")));
rewrite(671).repItem(new Item((short) 158, (byte) 1, (short) -1, getNamedTag("1.14 Smithing Table")));
rewrite(872).repItem(new Item((short) 158, (byte) 1, (short) -1, getNamedTag("1.14 Stonecutter")));
//rewrite(873).repItem(new Item((short) 1, (byte) 1, (short) -1, getNamedTag("1.14 Bell"))); //TODO
rewrite(874).repItem(new Item((short) 234, (byte) 1, (short) -1, getNamedTag("1.14 Lantern")));
rewrite(875).repItem(new Item((short) 820, (byte) 1, (short) -1, getNamedTag("1.14 Sweet Berries"))); //TODO
rewrite(876).repItem(new Item((short) 146, (byte) 1, (short) -1, getNamedTag("1.14 Campfire")));
//rewrite(856).repItem(new Item((short) 525, (byte) 1, (short) -1, getNamedTag("1.14 Crossbow"))); //TODO
//TODO: Signs, slabs, walls, stairs
} }
@Override @Override
@ -642,6 +676,10 @@ public class BlockItemPackets1_14 extends BlockItemRewriter<Protocol1_13_2To1_14
public static int getOldItemId(int id) { public static int getOldItemId(int id) {
Integer oldId = MappingData.oldToNewItems.inverse().get(id); Integer oldId = MappingData.oldToNewItems.inverse().get(id);
return oldId != null ? oldId : 1; if (oldId == null) {
ViaBackwards.getPlatform().getLogger().warning("Missing 1.13.2 item for 1.14 item " + id);
return 1;
}
return oldId;
} }
} }

View File

@ -524,7 +524,7 @@
"minecraft:cut_red_sandstone_slab[type=bottom,waterlogged=false]": "minecraft:red_sandstone_slab[type=bottom,waterlogged=false]", "minecraft:cut_red_sandstone_slab[type=bottom,waterlogged=false]": "minecraft:red_sandstone_slab[type=bottom,waterlogged=false]",
"minecraft:cut_red_sandstone_slab[type=double,waterlogged=true]": "minecraft:red_sandstone_slab[type=double,waterlogged=true]", "minecraft:cut_red_sandstone_slab[type=double,waterlogged=true]": "minecraft:red_sandstone_slab[type=double,waterlogged=true]",
"minecraft:cut_red_sandstone_slab[type=double,waterlogged=false]": "minecraft:red_sandstone_slab[type=double,waterlogged=false]", "minecraft:cut_red_sandstone_slab[type=double,waterlogged=false]": "minecraft:red_sandstone_slab[type=double,waterlogged=false]",
"minecraft:bamboo_sapling": "minecraft:jungle_sapling", "minecraft:bamboo_sapling": "minecraft:jungle_sapling[stage=0]",
"minecraft:bamboo": "minecraft:sugar_cane[age=0]", "minecraft:bamboo": "minecraft:sugar_cane[age=0]",
"minecraft:potted_bamboo": "minecraft:potted_cactus", "minecraft:potted_bamboo": "minecraft:potted_cactus",
"minecraft:polished_granite_stairs[facing=north,half=top,shape=straight,waterlogged=true]": "minecraft:stone_brick_stairs[facing=north,half=top,shape=straight,waterlogged=true]", "minecraft:polished_granite_stairs[facing=north,half=top,shape=straight,waterlogged=true]": "minecraft:stone_brick_stairs[facing=north,half=top,shape=straight,waterlogged=true]",
@ -2535,6 +2535,122 @@
"minecraft:composter[level=5]": "minecraft:cauldron[level=2]", "minecraft:composter[level=5]": "minecraft:cauldron[level=2]",
"minecraft:composter[level=6]": "minecraft:cauldron[level=2]", "minecraft:composter[level=6]": "minecraft:cauldron[level=2]",
"minecraft:composter[level=7]": "minecraft:cauldron[level=2]", "minecraft:composter[level=7]": "minecraft:cauldron[level=2]",
"minecraft:composter[level=8]": "minecraft:cauldron[level=3]" "minecraft:composter[level=8]": "minecraft:cauldron[level=3]",
"minecraft:scaffolding[bottom=true,distance=0,waterlogged=true]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=0,waterlogged=false]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=1,waterlogged=true]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=1,waterlogged=false]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=2,waterlogged=true]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=2,waterlogged=false]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=3,waterlogged=true]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=3,waterlogged=false]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=4,waterlogged=true]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=4,waterlogged=false]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=5,waterlogged=true]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=5,waterlogged=false]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=6,waterlogged=true]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=6,waterlogged=false]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=7,waterlogged=true]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=true,distance=7,waterlogged=false]": "minecraft:hay_block[axis=x]",
"minecraft:scaffolding[bottom=false,distance=0,waterlogged=true]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=0,waterlogged=false]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=1,waterlogged=true]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=1,waterlogged=false]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=2,waterlogged=true]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=2,waterlogged=false]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=3,waterlogged=true]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=3,waterlogged=false]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=4,waterlogged=true]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=4,waterlogged=false]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=5,waterlogged=true]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=5,waterlogged=false]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=6,waterlogged=true]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=6,waterlogged=false]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=7,waterlogged=true]": "minecraft:hay_block[axis=y]",
"minecraft:scaffolding[bottom=false,distance=7,waterlogged=false]": "minecraft:hay_block[axis=y]",
"minecraft:grindstone[face=floor,facing=north]": "minecraft:anvil[facing=north]",
"minecraft:grindstone[face=floor,facing=south]": "minecraft:anvil[facing=south]",
"minecraft:grindstone[face=floor,facing=west]": "minecraft:anvil[facing=west]",
"minecraft:grindstone[face=floor,facing=east]": "minecraft:anvil[facing=east]",
"minecraft:grindstone[face=wall,facing=north]": "minecraft:anvil[facing=east]",
"minecraft:grindstone[face=wall,facing=south]": "minecraft:anvil[facing=south]",
"minecraft:grindstone[face=wall,facing=west]": "minecraft:anvil[facing=west]",
"minecraft:grindstone[face=wall,facing=east]": "minecraft:anvil[facing=east]",
"minecraft:grindstone[face=ceiling,facing=north]": "minecraft:anvil[facing=east]",
"minecraft:grindstone[face=ceiling,facing=south]": "minecraft:anvil[facing=south]",
"minecraft:grindstone[face=ceiling,facing=west]": "minecraft:anvil[facing=west]",
"minecraft:grindstone[face=ceiling,facing=east]": "minecraft:anvil[facing=east]",
"minecraft:lectern[facing=north,has_book=true,powered=true]": "minecraft:bookshelf",
"minecraft:lectern[facing=north,has_book=true,powered=false]": "minecraft:bookshelf",
"minecraft:lectern[facing=north,has_book=false,powered=true]": "minecraft:bookshelf",
"minecraft:lectern[facing=north,has_book=false,powered=false]": "minecraft:bookshelf",
"minecraft:lectern[facing=south,has_book=true,powered=true]": "minecraft:bookshelf",
"minecraft:lectern[facing=south,has_book=true,powered=false]": "minecraft:bookshelf",
"minecraft:lectern[facing=south,has_book=false,powered=true]": "minecraft:bookshelf",
"minecraft:lectern[facing=south,has_book=false,powered=false]": "minecraft:bookshelf",
"minecraft:lectern[facing=west,has_book=true,powered=true]": "minecraft:bookshelf",
"minecraft:lectern[facing=west,has_book=true,powered=false]": "minecraft:bookshelf",
"minecraft:lectern[facing=west,has_book=false,powered=true]": "minecraft:bookshelf",
"minecraft:lectern[facing=west,has_book=false,powered=false]": "minecraft:bookshelf",
"minecraft:lectern[facing=east,has_book=true,powered=true]": "minecraft:bookshelf",
"minecraft:lectern[facing=east,has_book=true,powered=false]": "minecraft:bookshelf",
"minecraft:lectern[facing=east,has_book=false,powered=true]": "minecraft:bookshelf",
"minecraft:lectern[facing=east,has_book=false,powered=false]": "minecraft:bookshelf",
"minecraft:bell[attachment=floor,facing=north]": "minecraft:cocoa[age=2,facing=north]",
"minecraft:bell[attachment=floor,facing=south]": "minecraft:cocoa[age=2,facing=south]",
"minecraft:bell[attachment=floor,facing=west]": "minecraft:cocoa[age=2,facing=west]",
"minecraft:bell[attachment=floor,facing=east]": "minecraft:cocoa[age=2,facing=east]",
"minecraft:bell[attachment=ceiling,facing=north]": "minecraft:cocoa[age=2,facing=north]",
"minecraft:bell[attachment=ceiling,facing=south]": "minecraft:cocoa[age=2,facing=south]",
"minecraft:bell[attachment=ceiling,facing=west]": "minecraft:cocoa[age=2,facing=west]",
"minecraft:bell[attachment=ceiling,facing=east]": "minecraft:cocoa[age=2,facing=east]",
"minecraft:bell[attachment=single_wall,facing=north]": "minecraft:cocoa[age=2,facing=north]",
"minecraft:bell[attachment=single_wall,facing=south]": "minecraft:cocoa[age=2,facing=south]",
"minecraft:bell[attachment=single_wall,facing=west]": "minecraft:cocoa[age=2,facing=west]",
"minecraft:bell[attachment=single_wall,facing=east]": "minecraft:cocoa[age=2,facing=east]",
"minecraft:bell[attachment=double_wall,facing=north]": "minecraft:cocoa[age=2,facing=north]",
"minecraft:bell[attachment=double_wall,facing=south]": "minecraft:cocoa[age=2,facing=south]",
"minecraft:bell[attachment=double_wall,facing=west]": "minecraft:cocoa[age=2,facing=west]",
"minecraft:bell[attachment=double_wall,facing=east]": "minecraft:cocoa[age=2,facing=east]",
"minecraft:campfire[facing=north,lit=true,signal_fire=true,waterlogged=true]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=north,lit=true,signal_fire=true,waterlogged=false]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=north,lit=true,signal_fire=false,waterlogged=true]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=north,lit=true,signal_fire=false,waterlogged=false]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=north,lit=false,signal_fire=true,waterlogged=true]": "minecraft:oak_slab[type=bottom,waterlogged=true]",
"minecraft:campfire[facing=north,lit=false,signal_fire=true,waterlogged=false]": "minecraft:oak_slab[type=bottom,waterlogged=false]",
"minecraft:campfire[facing=north,lit=false,signal_fire=false,waterlogged=true]": "minecraft:oak_slab[type=bottom,waterlogged=true]",
"minecraft:campfire[facing=north,lit=false,signal_fire=false,waterlogged=false]": "minecraft:oak_slab[type=bottom,waterlogged=false]",
"minecraft:campfire[facing=south,lit=true,signal_fire=true,waterlogged=true]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=south,lit=true,signal_fire=true,waterlogged=false]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=south,lit=true,signal_fire=false,waterlogged=true]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=south,lit=true,signal_fire=false,waterlogged=false]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=south,lit=false,signal_fire=true,waterlogged=true]": "minecraft:oak_slab[type=bottom,waterlogged=true]",
"minecraft:campfire[facing=south,lit=false,signal_fire=true,waterlogged=false]": "minecraft:oak_slab[type=bottom,waterlogged=false]",
"minecraft:campfire[facing=south,lit=false,signal_fire=false,waterlogged=true]": "minecraft:oak_slab[type=bottom,waterlogged=true]",
"minecraft:campfire[facing=south,lit=false,signal_fire=false,waterlogged=false]": "minecraft:oak_slab[type=bottom,waterlogged=false]",
"minecraft:campfire[facing=west,lit=true,signal_fire=true,waterlogged=true]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=west,lit=true,signal_fire=true,waterlogged=false]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=west,lit=true,signal_fire=false,waterlogged=true]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=west,lit=true,signal_fire=false,waterlogged=false]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=west,lit=false,signal_fire=true,waterlogged=true]": "minecraft:oak_slab[type=bottom,waterlogged=true]",
"minecraft:campfire[facing=west,lit=false,signal_fire=true,waterlogged=false]": "minecraft:oak_slab[type=bottom,waterlogged=false]",
"minecraft:campfire[facing=west,lit=false,signal_fire=false,waterlogged=true]": "minecraft:oak_slab[type=bottom,waterlogged=true]",
"minecraft:campfire[facing=west,lit=false,signal_fire=false,waterlogged=false]": "minecraft:oak_slab[type=bottom,waterlogged=false]",
"minecraft:campfire[facing=east,lit=true,signal_fire=true,waterlogged=true]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=east,lit=true,signal_fire=true,waterlogged=false]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=east,lit=true,signal_fire=false,waterlogged=true]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=east,lit=true,signal_fire=false,waterlogged=false]": "minecraft:fire[age=0,east=true,north=true,south=true,up=false,west=true]",
"minecraft:campfire[facing=east,lit=false,signal_fire=true,waterlogged=true]": "minecraft:oak_slab[type=bottom,waterlogged=true]",
"minecraft:campfire[facing=east,lit=false,signal_fire=true,waterlogged=false]": "minecraft:oak_slab[type=bottom,waterlogged=false]",
"minecraft:campfire[facing=east,lit=false,signal_fire=false,waterlogged=true]": "minecraft:oak_slab[type=bottom,waterlogged=true]",
"minecraft:campfire[facing=east,lit=false,signal_fire=false,waterlogged=false]": "minecraft:oak_slab[type=bottom,waterlogged=false]",
"minecraft:stonecutter[facing=north]": "minecraft:crafting_table",
"minecraft:stonecutter[facing=south]": "minecraft:crafting_table",
"minecraft:stonecutter[facing=west]": "minecraft:crafting_table",
"minecraft:stonecutter[facing=east]": "minecraft:crafting_table",
"minecraft:sweet_berry_bush[age=0]": "minecraft:sugar_cane[age=0]",
"minecraft:sweet_berry_bush[age=1]": "minecraft:sugar_cane[age=0]",
"minecraft:sweet_berry_bush[age=2]": "minecraft:sugar_cane[age=0]",
"minecraft:sweet_berry_bush[age=3]": "minecraft:sugar_cane[age=0]"
} }
} }