mirror of
https://github.com/ViaVersion/ViaBackwards.git
synced 2024-11-22 12:16:21 +01:00
Add item mappings, rename carpets tag for older versions
This commit is contained in:
parent
dfa778942c
commit
56dfc985d2
@ -25,6 +25,7 @@ import com.viaversion.viabackwards.protocol.protocol1_18_2to1_19.data.BackwardsM
|
||||
import com.viaversion.viabackwards.protocol.protocol1_18_2to1_19.packets.BlockItemPackets1_19;
|
||||
import com.viaversion.viabackwards.protocol.protocol1_18_2to1_19.packets.EntityPackets1_19;
|
||||
import com.viaversion.viaversion.api.connection.UserConnection;
|
||||
import com.viaversion.viaversion.api.minecraft.RegistryType;
|
||||
import com.viaversion.viaversion.api.minecraft.entities.Entity1_19Types;
|
||||
import com.viaversion.viaversion.api.protocol.remapper.PacketRemapper;
|
||||
import com.viaversion.viaversion.api.rewriter.EntityRewriter;
|
||||
@ -113,7 +114,11 @@ public final class Protocol1_18_2To1_19 extends BackwardsProtocol<ClientboundPac
|
||||
}
|
||||
});
|
||||
|
||||
new TagRewriter(this).registerGeneric(ClientboundPackets1_19.TAGS);
|
||||
final TagRewriter tagRewriter = new TagRewriter(this);
|
||||
tagRewriter.removeTags("minecraft:cat_variant");
|
||||
tagRewriter.renameTag(RegistryType.BLOCK, "minecraft:wool_carpets", "minecraft:carpets");
|
||||
tagRewriter.renameTag(RegistryType.ITEM, "minecraft:wool_carpets", "minecraft:carpets");
|
||||
tagRewriter.registerGeneric(ClientboundPackets1_19.TAGS);
|
||||
|
||||
new StatisticsRewriter(this).register(ClientboundPackets1_19.STATISTICS);
|
||||
|
||||
|
@ -53,14 +53,14 @@ public final class EntityPackets1_19 extends EntityRewriter<Protocol1_18_2To1_19
|
||||
protocol.registerClientbound(ClientboundPackets1_19.SPAWN_ENTITY, new PacketRemapper() {
|
||||
@Override
|
||||
public void registerMap() {
|
||||
map(Type.VAR_INT); // 0 - Entity id
|
||||
map(Type.UUID); // 1 - Entity UUID
|
||||
map(Type.VAR_INT); // 2 - Entity Type
|
||||
map(Type.DOUBLE); // 3 - X
|
||||
map(Type.DOUBLE); // 4 - Y
|
||||
map(Type.DOUBLE); // 5 - Z
|
||||
map(Type.BYTE); // 6 - Pitch
|
||||
map(Type.BYTE); // 7 - Yaw
|
||||
map(Type.VAR_INT); // Entity id
|
||||
map(Type.UUID); // Entity UUID
|
||||
map(Type.VAR_INT); // Entity Type
|
||||
map(Type.DOUBLE); // X
|
||||
map(Type.DOUBLE); // Y
|
||||
map(Type.DOUBLE); // Z
|
||||
map(Type.BYTE); // Pitch
|
||||
map(Type.BYTE); // Yaw
|
||||
handler(wrapper -> {
|
||||
final byte headYaw = wrapper.read(Type.BYTE);
|
||||
int data = wrapper.read(Type.VAR_INT);
|
||||
|
@ -584,6 +584,14 @@
|
||||
"minecraft:reinforced_deepslate": {
|
||||
"id": "minecraft:obsidian",
|
||||
"name": "1.19 Reinforced Deepslate"
|
||||
},
|
||||
"minecraft:echo_shard": {
|
||||
"id": "minecraft:prismarine_shard",
|
||||
"name": "1.19 Echo Shard"
|
||||
},
|
||||
"minecraft:recovery_compass": {
|
||||
"id": "minecraft:compass",
|
||||
"name": "1.19 Recovery Compass"
|
||||
}
|
||||
},
|
||||
"particles": {
|
||||
|
Loading…
Reference in New Issue
Block a user