3
0
Mirror von https://github.com/ViaVersion/ViaVersion.git synchronisiert 2024-11-03 14:50:30 +01:00

Merge pull request #837 from creeper123123321/dev2

Revert mappings changes and update handlers
Dieser Commit ist enthalten in:
Mats 2018-06-04 23:34:32 +02:00 committet von GitHub
Commit 235948a001
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 4AEE18F83AFDEB23
7 geänderte Dateien mit 8462 neuen und 8390 gelöschten Zeilen

Datei anzeigen

@ -8,11 +8,11 @@ import us.myles.ViaVersion.protocols.protocolsnapshotto1_12_2.providers.BlockEnt
import us.myles.ViaVersion.protocols.protocolsnapshotto1_12_2.storage.BlockStorage;
public class BannerHandler implements BlockEntityProvider.BlockEntityHandler {
private final int WALL_BANNER_START = 7020; // 4 each
private final int WALL_BANNER_STOP = 7083;
private final int WALL_BANNER_START = 7092; // 4 each
private final int WALL_BANNER_STOP = 7155;
private final int BANNER_START = 6764; // 16 each
private final int BANNER_STOP = 7019;
private final int BANNER_START = 6836; // 16 each
private final int BANNER_STOP = 7091;
@Override
public int transform(UserConnection user, CompoundTag tag) {

Datei anzeigen

@ -20,7 +20,7 @@ public class BedHandler implements BlockEntityProvider.BlockEntityHandler {
}
// RED_BED + FIRST_BED
int blockId = storage.get(position).getOriginal() - 882 + 658;
int blockId = storage.get(position).getOriginal() - 954 + 730;
int color = (int) tag.get("color").getValue();
blockId += (color * 16);

Datei anzeigen

@ -12,28 +12,28 @@ public class FlowerPotHandler implements BlockEntityProvider.BlockEntityHandler
private static final Map<Pair<String, Integer>, Integer> flowers = new ConcurrentHashMap<>();
static {
register("minecraft:air", 0, 5175);
register("minecraft:sapling", 0, 5176);
register("minecraft:sapling", 1, 5177);
register("minecraft:sapling", 2, 5178);
register("minecraft:sapling", 3, 5179);
register("minecraft:sapling", 4, 5180);
register("minecraft:sapling", 5, 5181);
register("minecraft:tallgrass", 2, 5182);
register("minecraft:yellow_flower", 0, 5183);
register("minecraft:red_flower", 0, 5184);
register("minecraft:red_flower", 1, 5185);
register("minecraft:red_flower", 2, 5186);
register("minecraft:red_flower", 3, 5187);
register("minecraft:red_flower", 4, 5188);
register("minecraft:red_flower", 5, 5189);
register("minecraft:red_flower", 6, 5190);
register("minecraft:red_flower", 7, 5191);
register("minecraft:red_flower", 8, 5192);
register("minecraft:red_mushroom", 0, 5193);
register("minecraft:brown_mushroom", 0, 5194);
register("minecraft:deadbush", 0, 5195);
register("minecraft:cactus", 0, 5196);
register("minecraft:air", 0, 5247);
register("minecraft:sapling", 0, 5248);
register("minecraft:sapling", 1, 5249);
register("minecraft:sapling", 2, 5250);
register("minecraft:sapling", 3, 5251);
register("minecraft:sapling", 4, 5252);
register("minecraft:sapling", 5, 5253);
register("minecraft:tallgrass", 2, 5254);
register("minecraft:yellow_flower", 0, 5255);
register("minecraft:red_flower", 0, 5256);
register("minecraft:red_flower", 1, 5257);
register("minecraft:red_flower", 2, 5258);
register("minecraft:red_flower", 3, 5259);
register("minecraft:red_flower", 4, 5260);
register("minecraft:red_flower", 5, 5261);
register("minecraft:red_flower", 6, 5262);
register("minecraft:red_flower", 7, 5263);
register("minecraft:red_flower", 8, 5264);
register("minecraft:red_mushroom", 0, 5265);
register("minecraft:brown_mushroom", 0, 5266);
register("minecraft:deadbush", 0, 5267);
register("minecraft:cactus", 0, 5268);
}

Datei anzeigen

@ -8,8 +8,8 @@ import us.myles.ViaVersion.protocols.protocolsnapshotto1_12_2.providers.BlockEnt
import us.myles.ViaVersion.protocols.protocolsnapshotto1_12_2.storage.BlockStorage;
public class SkullHandler implements BlockEntityProvider.BlockEntityHandler {
private final int SKULL_WALL_START = 5357;
private final int SKULL_END = 5476;
private final int SKULL_WALL_START = 5429;
private final int SKULL_END = 5548;
@Override
public int transform(UserConnection user, CompoundTag tag) {
BlockStorage storage = user.get(BlockStorage.class);

Datei anzeigen

@ -17,24 +17,24 @@ public class BlockStorage extends StoredObject {
static {
// Flower pots
whitelist.add(5175);
whitelist.add(5247);
// Add those red beds
for (int i = 0; i < 16; i++)
whitelist.add(882 + i);
whitelist.add(954 + i);
// Add the white banners
for (int i = 0; i < 20; i++)
whitelist.add(6764 + i);
whitelist.add(6836 + i);
// Add the white wall banners
for (int i = 0; i < 4; i++) {
whitelist.add(7020 + i);
whitelist.add(7092 + i);
}
// Skeleton skulls
for (int i = 0; i < 5; i++)
whitelist.add(5357 + i);
whitelist.add(5429 + i);
}
private Map<Position, ReplacementData> blocks = new ConcurrentHashMap<>();

Datei anzeigen

@ -114,26 +114,26 @@
"281": "minecraft:spruce_log[axis=z]",
"282": "minecraft:birch_log[axis=z]",
"283": "minecraft:jungle_log[axis=z]",
"284": "minecraft:oak_bark",
"285": "minecraft:spruce_bark",
"286": "minecraft:birch_bark",
"287": "minecraft:jungle_bark",
"288": "minecraft:oak_leaves[check_decay=false,decayable=true]",
"289": "minecraft:spruce_leaves[check_decay=false,decayable=true]",
"290": "minecraft:birch_leaves[check_decay=false,decayable=true]",
"291": "minecraft:jungle_leaves[check_decay=false,decayable=true]",
"292": "minecraft:oak_leaves[check_decay=false,decayable=false]",
"293": "minecraft:spruce_leaves[check_decay=false,decayable=false]",
"294": "minecraft:birch_leaves[check_decay=false,decayable=false]",
"295": "minecraft:jungle_leaves[check_decay=false,decayable=false]",
"296": "minecraft:oak_leaves[check_decay=true,decayable=true]",
"297": "minecraft:spruce_leaves[check_decay=true,decayable=true]",
"298": "minecraft:birch_leaves[check_decay=true,decayable=true]",
"299": "minecraft:jungle_leaves[check_decay=true,decayable=true]",
"300": "minecraft:oak_leaves[check_decay=true,decayable=false]",
"301": "minecraft:spruce_leaves[check_decay=true,decayable=false]",
"302": "minecraft:birch_leaves[check_decay=true,decayable=false]",
"303": "minecraft:jungle_leaves[check_decay=true,decayable=false]",
"284": "minecraft:oak_bark[axis=y]",
"285": "minecraft:spruce_bark[axis=y]",
"286": "minecraft:birch_bark[axis=y]",
"287": "minecraft:jungle_bark[axis=y]",
"288": "minecraft:oak_leaves[distance=1,persistent=false]",
"289": "minecraft:spruce_leaves[distance=1,persistent=false]",
"290": "minecraft:birch_leaves[distance=1,persistent=false]",
"291": "minecraft:jungle_leaves[distance=1,persistent=false]",
"292": "minecraft:oak_leaves[distance=1,persistent=true]",
"293": "minecraft:spruce_leaves[distance=1,persistent=true]",
"294": "minecraft:birch_leaves[distance=1,persistent=true]",
"295": "minecraft:jungle_leaves[distance=1,persistent=true]",
"296": "minecraft:oak_leaves[distance=2,persistent=false]",
"297": "minecraft:spruce_leaves[distance=2,persistent=false]",
"298": "minecraft:birch_leaves[distance=2,persistent=false]",
"299": "minecraft:jungle_leaves[distance=2,persistent=false]",
"300": "minecraft:oak_leaves[distance=2,persistent=true]",
"301": "minecraft:spruce_leaves[distance=2,persistent=true]",
"302": "minecraft:birch_leaves[distance=2,persistent=true]",
"303": "minecraft:jungle_leaves[distance=2,persistent=true]",
"304": "minecraft:sponge",
"305": "minecraft:wet_sponge",
"320": "minecraft:glass",
@ -448,16 +448,16 @@
"1106": "minecraft:lever[face=wall,facing=west,powered=false]",
"1107": "minecraft:lever[face=wall,facing=south,powered=false]",
"1108": "minecraft:lever[face=wall,facing=north,powered=false]",
"1109": "minecraft:lever[face=floor,facing=north,powered=false]",
"1110": "minecraft:lever[face=floor,facing=west,powered=false]",
"1109": "minecraft:lever[face=floor,facing=west,powered=false]",
"1110": "minecraft:lever[face=floor,facing=north,powered=false]",
"1111": "minecraft:lever[face=ceiling,facing=north,powered=false]",
"1112": "minecraft:lever[face=ceiling,facing=west,powered=true]",
"1113": "minecraft:lever[face=wall,facing=east,powered=true]",
"1114": "minecraft:lever[face=wall,facing=west,powered=true]",
"1115": "minecraft:lever[face=wall,facing=south,powered=true]",
"1116": "minecraft:lever[face=wall,facing=north,powered=true]",
"1117": "minecraft:lever[face=floor,facing=north,powered=true]",
"1118": "minecraft:lever[face=floor,facing=west,powered=true]",
"1117": "minecraft:lever[face=floor,facing=east,powered=true]",
"1118": "minecraft:lever[face=floor,facing=north,powered=true]",
"1119": "minecraft:lever[face=ceiling,facing=north,powered=true]",
"1120": "minecraft:stone_pressure_plate[powered=false]",
"1121": "minecraft:stone_pressure_plate[powered=true]",
@ -690,22 +690,22 @@
"1685": "minecraft:melon_stem[age=5]",
"1686": "minecraft:melon_stem[age=6]",
"1687": "minecraft:melon_stem[age=7]",
"1696": "minecraft:vine[east=false,north=false,south=false,up=true,west=false]",
"1697": "minecraft:vine[east=false,north=false,south=true,up=true,west=false]",
"1698": "minecraft:vine[east=false,north=false,south=false,up=true,west=true]",
"1699": "minecraft:vine[east=false,north=false,south=true,up=true,west=true]",
"1700": "minecraft:vine[east=false,north=true,south=false,up=true,west=false]",
"1701": "minecraft:vine[east=false,north=true,south=true,up=true,west=false]",
"1702": "minecraft:vine[east=false,north=true,south=false,up=true,west=true]",
"1703": "minecraft:vine[east=false,north=true,south=true,up=true,west=true]",
"1704": "minecraft:vine[east=true,north=false,south=false,up=true,west=false]",
"1705": "minecraft:vine[east=true,north=false,south=true,up=true,west=false]",
"1706": "minecraft:vine[east=true,north=false,south=false,up=true,west=true]",
"1707": "minecraft:vine[east=true,north=false,south=true,up=true,west=true]",
"1708": "minecraft:vine[east=true,north=true,south=false,up=true,west=false]",
"1709": "minecraft:vine[east=true,north=true,south=true,up=true,west=false]",
"1710": "minecraft:vine[east=true,north=true,south=false,up=true,west=true]",
"1711": "minecraft:vine[east=true,north=true,south=true,up=true,west=true]",
"1696": "minecraft:vine[east=false,north=false,south=false,up=false,west=false]",
"1697": "minecraft:vine[east=false,north=false,south=true,up=false,west=false]",
"1698": "minecraft:vine[east=false,north=false,south=false,up=false,west=true]",
"1699": "minecraft:vine[east=false,north=false,south=true,up=false,west=true]",
"1700": "minecraft:vine[east=false,north=true,south=false,up=false,west=false]",
"1701": "minecraft:vine[east=false,north=true,south=true,up=false,west=false]",
"1702": "minecraft:vine[east=false,north=true,south=false,up=false,west=true]",
"1703": "minecraft:vine[east=false,north=true,south=true,up=false,west=true]",
"1704": "minecraft:vine[east=true,north=false,south=false,up=false,west=false]",
"1705": "minecraft:vine[east=true,north=false,south=true,up=false,west=false]",
"1706": "minecraft:vine[east=true,north=false,south=false,up=false,west=true]",
"1707": "minecraft:vine[east=true,north=false,south=true,up=false,west=true]",
"1708": "minecraft:vine[east=true,north=true,south=false,up=false,west=false]",
"1709": "minecraft:vine[east=true,north=true,south=true,up=false,west=false]",
"1710": "minecraft:vine[east=true,north=true,south=false,up=false,west=true]",
"1711": "minecraft:vine[east=true,north=true,south=true,up=false,west=true]",
"1712": "minecraft:oak_fence_gate[facing=south,in_wall=false,open=false,powered=false]",
"1713": "minecraft:oak_fence_gate[facing=west,in_wall=false,open=false,powered=false]",
"1714": "minecraft:oak_fence_gate[facing=north,in_wall=false,open=false,powered=false]",
@ -1127,22 +1127,22 @@
"2573": "minecraft:green_stained_glass_pane[east=false,north=false,south=false,waterlogged=false,west=false]",
"2574": "minecraft:red_stained_glass_pane[east=false,north=false,south=false,waterlogged=false,west=false]",
"2575": "minecraft:black_stained_glass_pane[east=false,north=false,south=false,waterlogged=false,west=false]",
"2576": "minecraft:acacia_leaves[check_decay=false,decayable=true]",
"2577": "minecraft:dark_oak_leaves[check_decay=false,decayable=true]",
"2580": "minecraft:acacia_leaves[check_decay=false,decayable=false]",
"2581": "minecraft:dark_oak_leaves[check_decay=false,decayable=false]",
"2584": "minecraft:acacia_leaves[check_decay=true,decayable=true]",
"2585": "minecraft:dark_oak_leaves[check_decay=true,decayable=true]",
"2588": "minecraft:acacia_leaves[check_decay=true,decayable=false]",
"2589": "minecraft:dark_oak_leaves[check_decay=true,decayable=false]",
"2576": "minecraft:acacia_leaves[distance=1,persistent=false]",
"2577": "minecraft:dark_oak_leaves[distance=1,persistent=false]",
"2580": "minecraft:acacia_leaves[distance=1,persistent=true]",
"2581": "minecraft:dark_oak_leaves[distance=1,persistent=true]",
"2584": "minecraft:acacia_leaves[distance=2,persistent=false]",
"2585": "minecraft:dark_oak_leaves[distance=2,persistent=false]",
"2588": "minecraft:acacia_leaves[distance=2,persistent=true]",
"2589": "minecraft:dark_oak_leaves[distance=2,persistent=true]",
"2592": "minecraft:acacia_log[axis=y]",
"2593": "minecraft:dark_oak_log[axis=y]",
"2596": "minecraft:acacia_log[axis=x]",
"2597": "minecraft:dark_oak_log[axis=x]",
"2600": "minecraft:acacia_log[axis=z]",
"2601": "minecraft:dark_oak_log[axis=z]",
"2604": "minecraft:acacia_bark",
"2605": "minecraft:dark_oak_bark",
"2604": "minecraft:acacia_bark[axis=y]",
"2605": "minecraft:dark_oak_bark[axis=y]",
"2608": "minecraft:acacia_stairs[facing=east,half=bottom,shape=straight,waterlogged=false]",
"2609": "minecraft:acacia_stairs[facing=west,half=bottom,shape=straight,waterlogged=false]",
"2610": "minecraft:acacia_stairs[facing=south,half=bottom,shape=straight,waterlogged=false]",