2023-03-23 23:41:41 +01:00
|
|
|
namespace MinecraftClient.Mapping;
|
|
|
|
|
|
|
|
|
|
public enum EntityMetaDataType
|
|
|
|
|
{
|
|
|
|
|
Byte,
|
2023-03-27 18:22:50 +08:00
|
|
|
Short, // 1.8 only
|
|
|
|
|
Int, // 1.8 only
|
|
|
|
|
Vector3Int, // 1.8 only (not used by the game)
|
2023-03-23 23:41:41 +01:00
|
|
|
VarInt,
|
|
|
|
|
VarLong,
|
|
|
|
|
Float,
|
|
|
|
|
String,
|
|
|
|
|
Chat,
|
|
|
|
|
OptionalChat,
|
|
|
|
|
Slot,
|
|
|
|
|
Boolean,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// Float x3
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
Rotation,
|
|
|
|
|
Position,
|
|
|
|
|
OptionalPosition,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
Direction,
|
|
|
|
|
OptionalUuid,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
feat: add MC 1.21.5 (protocol 770) support
Full protocol adaptation for Minecraft 1.21.5:
- Protocol version mapping: 770 -> 1.21.5
- Packet palette: AddExperienceOrb removed (S2C), TestInstanceBlockStatus
added (S2C), SetTestBlock and TestInstanceBlockAction added (C2S)
- Entity metadata palette: 5 new serializer types (OptionalLivingEntityReference,
CowVariant, WolfSoundVariant, PigVariant, ChickenVariant), OPTIONAL_UUID
replaced by OPTIONAL_LIVING_ENTITY_REFERENCE
- Item palette: 11 new items (Bush, FireflyBush, DryShortGrass, DryTallGrass,
Wildflowers, LeafLitter, CactusFlower, TestBlock, TestInstanceBlock,
BlueEgg, BrownEgg)
- Entity palette: Potion split into SplashPotion and LingeringPotion
- Block palette: 9 new blocks (bush, cactus_flower, firefly_bush, leaf_litter,
short_dry_grass, tall_dry_grass, test_block, test_instance_block, wildflowers)
- Structured components: 31 new components including tooltip_display, weapon,
blocks_attacks, potion_duration_scale, provides_trim_material,
provides_banner_patterns, break_sound, and 25 entity variant components;
unbreakable changed from Bool to Unit; instrument changed to EitherHolder
Made-with: Cursor
2026-03-21 00:48:27 +08:00
|
|
|
/// Boolean + UUID (1.21.5+, replaces OptionalUuid)
|
|
|
|
|
/// </summary>
|
|
|
|
|
OptionalLivingEntityReference,
|
|
|
|
|
/// <summary>
|
2023-03-24 20:51:10 +08:00
|
|
|
/// VarInt
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
BlockId,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt (0 for absent)
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
OptionalBlockId,
|
|
|
|
|
Nbt,
|
|
|
|
|
Particle,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
fix: add EntityMetadataPalette1206 for correct 1.20.6+ entity metadata parsing
1.20.6 introduced three new EntityDataSerializer types compared to 1.20.4:
- PARTICLES (id 18) - list of particles, inserted after PARTICLE
- WOLF_VARIANT (id 23) - wolf variant holder, inserted after CAT_VARIANT
- ARMADILLO_STATE (id 28) - armadillo state, inserted after SNIFFER_STATE
These insertions shifted subsequent serializer IDs, causing the 1.19.4
palette (EntityMetadataPalette1194) to misidentify metadata types on
1.20.6+ servers. This could lead to incorrect byte consumption and
potential packet parse failures when entities with affected metadata
types (e.g. wolves, armadillos, area effect clouds with particles)
were present.
Changes:
- Add Particles, WolfVariant, ArmadilloState to EntityMetaDataType enum
- Create EntityMetadataPalette1206 with correct 31-entry ID mapping
- Route 1.20.6+ to the new palette in EntityMetadataPalette.GetPalette()
- Add read logic for the three new types in DataTypes.cs
Verified on 1.21.1 vanilla server: cat, wolf, frog, armadillo, painting
entities all spawn without metadata parse errors.
Made-with: Cursor
2026-03-20 01:43:48 +08:00
|
|
|
/// List of Particle (1.20.6+)
|
|
|
|
|
/// </summary>
|
|
|
|
|
Particles,
|
|
|
|
|
/// <summary>
|
2023-03-24 20:51:10 +08:00
|
|
|
/// VarInt x3
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
VillagerData,
|
|
|
|
|
OptionalVarInt,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
Pose,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
CatVariant,
|
fix: add EntityMetadataPalette1206 for correct 1.20.6+ entity metadata parsing
1.20.6 introduced three new EntityDataSerializer types compared to 1.20.4:
- PARTICLES (id 18) - list of particles, inserted after PARTICLE
- WOLF_VARIANT (id 23) - wolf variant holder, inserted after CAT_VARIANT
- ARMADILLO_STATE (id 28) - armadillo state, inserted after SNIFFER_STATE
These insertions shifted subsequent serializer IDs, causing the 1.19.4
palette (EntityMetadataPalette1194) to misidentify metadata types on
1.20.6+ servers. This could lead to incorrect byte consumption and
potential packet parse failures when entities with affected metadata
types (e.g. wolves, armadillos, area effect clouds with particles)
were present.
Changes:
- Add Particles, WolfVariant, ArmadilloState to EntityMetaDataType enum
- Create EntityMetadataPalette1206 with correct 31-entry ID mapping
- Route 1.20.6+ to the new palette in EntityMetadataPalette.GetPalette()
- Add read logic for the three new types in DataTypes.cs
Verified on 1.21.1 vanilla server: cat, wolf, frog, armadillo, painting
entities all spawn without metadata parse errors.
Made-with: Cursor
2026-03-20 01:43:48 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt (1.20.6+)
|
|
|
|
|
/// </summary>
|
feat: add MC 1.21.5 (protocol 770) support
Full protocol adaptation for Minecraft 1.21.5:
- Protocol version mapping: 770 -> 1.21.5
- Packet palette: AddExperienceOrb removed (S2C), TestInstanceBlockStatus
added (S2C), SetTestBlock and TestInstanceBlockAction added (C2S)
- Entity metadata palette: 5 new serializer types (OptionalLivingEntityReference,
CowVariant, WolfSoundVariant, PigVariant, ChickenVariant), OPTIONAL_UUID
replaced by OPTIONAL_LIVING_ENTITY_REFERENCE
- Item palette: 11 new items (Bush, FireflyBush, DryShortGrass, DryTallGrass,
Wildflowers, LeafLitter, CactusFlower, TestBlock, TestInstanceBlock,
BlueEgg, BrownEgg)
- Entity palette: Potion split into SplashPotion and LingeringPotion
- Block palette: 9 new blocks (bush, cactus_flower, firefly_bush, leaf_litter,
short_dry_grass, tall_dry_grass, test_block, test_instance_block, wildflowers)
- Structured components: 31 new components including tooltip_display, weapon,
blocks_attacks, potion_duration_scale, provides_trim_material,
provides_banner_patterns, break_sound, and 25 entity variant components;
unbreakable changed from Bool to Unit; instrument changed to EitherHolder
Made-with: Cursor
2026-03-21 00:48:27 +08:00
|
|
|
CowVariant,
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt (1.20.6+)
|
|
|
|
|
/// </summary>
|
fix: add EntityMetadataPalette1206 for correct 1.20.6+ entity metadata parsing
1.20.6 introduced three new EntityDataSerializer types compared to 1.20.4:
- PARTICLES (id 18) - list of particles, inserted after PARTICLE
- WOLF_VARIANT (id 23) - wolf variant holder, inserted after CAT_VARIANT
- ARMADILLO_STATE (id 28) - armadillo state, inserted after SNIFFER_STATE
These insertions shifted subsequent serializer IDs, causing the 1.19.4
palette (EntityMetadataPalette1194) to misidentify metadata types on
1.20.6+ servers. This could lead to incorrect byte consumption and
potential packet parse failures when entities with affected metadata
types (e.g. wolves, armadillos, area effect clouds with particles)
were present.
Changes:
- Add Particles, WolfVariant, ArmadilloState to EntityMetaDataType enum
- Create EntityMetadataPalette1206 with correct 31-entry ID mapping
- Route 1.20.6+ to the new palette in EntityMetadataPalette.GetPalette()
- Add read logic for the three new types in DataTypes.cs
Verified on 1.21.1 vanilla server: cat, wolf, frog, armadillo, painting
entities all spawn without metadata parse errors.
Made-with: Cursor
2026-03-20 01:43:48 +08:00
|
|
|
WolfVariant,
|
feat: add MC 1.21.5 (protocol 770) support
Full protocol adaptation for Minecraft 1.21.5:
- Protocol version mapping: 770 -> 1.21.5
- Packet palette: AddExperienceOrb removed (S2C), TestInstanceBlockStatus
added (S2C), SetTestBlock and TestInstanceBlockAction added (C2S)
- Entity metadata palette: 5 new serializer types (OptionalLivingEntityReference,
CowVariant, WolfSoundVariant, PigVariant, ChickenVariant), OPTIONAL_UUID
replaced by OPTIONAL_LIVING_ENTITY_REFERENCE
- Item palette: 11 new items (Bush, FireflyBush, DryShortGrass, DryTallGrass,
Wildflowers, LeafLitter, CactusFlower, TestBlock, TestInstanceBlock,
BlueEgg, BrownEgg)
- Entity palette: Potion split into SplashPotion and LingeringPotion
- Block palette: 9 new blocks (bush, cactus_flower, firefly_bush, leaf_litter,
short_dry_grass, tall_dry_grass, test_block, test_instance_block, wildflowers)
- Structured components: 31 new components including tooltip_display, weapon,
blocks_attacks, potion_duration_scale, provides_trim_material,
provides_banner_patterns, break_sound, and 25 entity variant components;
unbreakable changed from Bool to Unit; instrument changed to EitherHolder
Made-with: Cursor
2026-03-21 00:48:27 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt (1.21.5+)
|
|
|
|
|
/// </summary>
|
|
|
|
|
WolfSoundVariant,
|
2023-03-23 23:41:41 +01:00
|
|
|
FrogVariant,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
feat: add MC 1.21.5 (protocol 770) support
Full protocol adaptation for Minecraft 1.21.5:
- Protocol version mapping: 770 -> 1.21.5
- Packet palette: AddExperienceOrb removed (S2C), TestInstanceBlockStatus
added (S2C), SetTestBlock and TestInstanceBlockAction added (C2S)
- Entity metadata palette: 5 new serializer types (OptionalLivingEntityReference,
CowVariant, WolfSoundVariant, PigVariant, ChickenVariant), OPTIONAL_UUID
replaced by OPTIONAL_LIVING_ENTITY_REFERENCE
- Item palette: 11 new items (Bush, FireflyBush, DryShortGrass, DryTallGrass,
Wildflowers, LeafLitter, CactusFlower, TestBlock, TestInstanceBlock,
BlueEgg, BrownEgg)
- Entity palette: Potion split into SplashPotion and LingeringPotion
- Block palette: 9 new blocks (bush, cactus_flower, firefly_bush, leaf_litter,
short_dry_grass, tall_dry_grass, test_block, test_instance_block, wildflowers)
- Structured components: 31 new components including tooltip_display, weapon,
blocks_attacks, potion_duration_scale, provides_trim_material,
provides_banner_patterns, break_sound, and 25 entity variant components;
unbreakable changed from Bool to Unit; instrument changed to EitherHolder
Made-with: Cursor
2026-03-21 00:48:27 +08:00
|
|
|
/// VarInt (1.21.5+)
|
|
|
|
|
/// </summary>
|
|
|
|
|
PigVariant,
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt (1.21.5+)
|
|
|
|
|
/// </summary>
|
|
|
|
|
ChickenVariant,
|
|
|
|
|
/// <summary>
|
2023-03-24 20:51:10 +08:00
|
|
|
/// String + Position
|
|
|
|
|
/// </summary>
|
2023-03-24 19:46:25 +08:00
|
|
|
GlobalPosition,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// Boolean + String + Position
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
OptionalGlobalPosition,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
PaintingVariant,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
SnifferState,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
fix: add EntityMetadataPalette1206 for correct 1.20.6+ entity metadata parsing
1.20.6 introduced three new EntityDataSerializer types compared to 1.20.4:
- PARTICLES (id 18) - list of particles, inserted after PARTICLE
- WOLF_VARIANT (id 23) - wolf variant holder, inserted after CAT_VARIANT
- ARMADILLO_STATE (id 28) - armadillo state, inserted after SNIFFER_STATE
These insertions shifted subsequent serializer IDs, causing the 1.19.4
palette (EntityMetadataPalette1194) to misidentify metadata types on
1.20.6+ servers. This could lead to incorrect byte consumption and
potential packet parse failures when entities with affected metadata
types (e.g. wolves, armadillos, area effect clouds with particles)
were present.
Changes:
- Add Particles, WolfVariant, ArmadilloState to EntityMetaDataType enum
- Create EntityMetadataPalette1206 with correct 31-entry ID mapping
- Route 1.20.6+ to the new palette in EntityMetadataPalette.GetPalette()
- Add read logic for the three new types in DataTypes.cs
Verified on 1.21.1 vanilla server: cat, wolf, frog, armadillo, painting
entities all spawn without metadata parse errors.
Made-with: Cursor
2026-03-20 01:43:48 +08:00
|
|
|
/// VarInt (1.20.6+)
|
|
|
|
|
/// </summary>
|
|
|
|
|
ArmadilloState,
|
|
|
|
|
/// <summary>
|
feat: add MC 1.21.9/1.21.10 (protocol 773) version constants and enum values
Register protocol 773 for Minecraft 1.21.9 and 1.21.10 (which share the
same protocol as a hotfix release). Update MCHighestVersion to 1.21.10.
Add 49 new item types (copper tools/armor, shelves, copper chests,
copper golem statue variants, oxidized lightning rods, iron chain, etc.),
2 new entity types (CopperGolem, Mannequin), 38 new block materials,
3 new entity metadata serializer types (CopperGolemState,
WeatheringCopperState, ResolvableProfile), and 6 new packet types
(DebugBlockValue, DebugChunkValue, DebugEntityValue, DebugEvent,
GameTestHighlightPos, CodeOfConduct, AcceptCodeOfConduct).
Chain item/block renamed to IronChain in 1.21.9; old enum values
retained for backward compatibility with older palettes.
Made-with: Cursor
2026-03-21 14:04:42 +08:00
|
|
|
/// VarInt (1.21.9+)
|
|
|
|
|
/// </summary>
|
|
|
|
|
CopperGolemState,
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt (1.21.9+)
|
|
|
|
|
/// </summary>
|
|
|
|
|
WeatheringCopperState,
|
|
|
|
|
/// <summary>
|
2023-03-24 20:51:10 +08:00
|
|
|
/// Float x3
|
|
|
|
|
/// </summary>
|
2023-03-23 23:41:41 +01:00
|
|
|
Vector3,
|
2023-03-24 20:51:10 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// Float x4
|
|
|
|
|
/// </summary>
|
feat: add MC 1.21.9/1.21.10 (protocol 773) version constants and enum values
Register protocol 773 for Minecraft 1.21.9 and 1.21.10 (which share the
same protocol as a hotfix release). Update MCHighestVersion to 1.21.10.
Add 49 new item types (copper tools/armor, shelves, copper chests,
copper golem statue variants, oxidized lightning rods, iron chain, etc.),
2 new entity types (CopperGolem, Mannequin), 38 new block materials,
3 new entity metadata serializer types (CopperGolemState,
WeatheringCopperState, ResolvableProfile), and 6 new packet types
(DebugBlockValue, DebugChunkValue, DebugEntityValue, DebugEvent,
GameTestHighlightPos, CodeOfConduct, AcceptCodeOfConduct).
Chain item/block renamed to IronChain in 1.21.9; old enum values
retained for backward compatibility with older palettes.
Made-with: Cursor
2026-03-21 14:04:42 +08:00
|
|
|
Quaternion,
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Either<GameProfile, Partial> + PlayerSkin.Patch (1.21.9+)
|
|
|
|
|
/// </summary>
|
feat: add palettes and enums for MC 1.21.11 (protocol 774)
Add 17 new items (spears, nautilus armor, spawn eggs, netherite horse armor),
4 new entities (CamelHusk, Nautilus, Parched, ZombieNautilus), and 2 new
entity metadata serializer types (ZombieNautilusVariant, HumanoidArm).
Generated ItemPalette12111 (1505 items), EntityPalette12111 (157 entities),
and EntityMetadataPalette12111 (39 serializers) from server reports.
Made-with: Cursor
2026-03-22 00:49:33 +08:00
|
|
|
ResolvableProfile,
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt (1.21.11+, holder registry ID)
|
|
|
|
|
/// </summary>
|
|
|
|
|
ZombieNautilusVariant,
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// VarInt (1.21.11+, 0=LEFT, 1=RIGHT)
|
|
|
|
|
/// </summary>
|
|
|
|
|
HumanoidArm
|
2023-03-23 23:41:41 +01:00
|
|
|
}
|