mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2026-08-15 13:04:36 +00:00
feat: add palettes and version constants for MC 1.21.2 (protocol 768)
Add item, entity, block, and metadata palettes for Minecraft 1.21.2: - ItemPalette1212: 1375 items (42 new: pale oak set, colored bundles, creaking heart/spawn egg, banner patterns) - EntityPalette1212: 150 entity types (boats split into per-wood-type entries, generic boat/chest_boat removed; added creaking, creaking_transient, pale oak boats) - Palette1212 (blocks): 1084 block types with state IDs generated from official 1.21.2 data reports (24 new pale oak blocks, creaking heart, pale moss variants) - EntityMetadataPalette: reuses 1206 (serializers unchanged in 1.21.2) Updated version infrastructure: - Protocol18.cs: MC_1_21_2_Version = 768, palette switch routing - ProtocolHandler.cs: version mapping 1.21.2 <-> 768 - Program.cs: MCHighestVersion bumped to 1.21.2 - ItemType.cs, EntityType.cs, Material.cs: new enum entries Note: packet palette, structured components, and protocol handler changes for 1.21.2 are not yet implemented — this commit covers palette/registry groundwork only. Made-with: Cursor
This commit is contained in:
parent
896263acc8
commit
df833ae2a8
10 changed files with 3476 additions and 9 deletions
1811
MinecraftClient/Mapping/BlockPalettes/Palette1212.cs
Normal file
1811
MinecraftClient/Mapping/BlockPalettes/Palette1212.cs
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -23,7 +23,7 @@ public abstract class EntityMetadataPalette
|
|||
<= Protocol18Handler.MC_1_19_2_Version => new EntityMetadataPalette1191(), // 1.13 - 1.19.2
|
||||
<= Protocol18Handler.MC_1_19_3_Version => new EntityMetadataPalette1193(), // 1.19.3
|
||||
< Protocol18Handler.MC_1_20_6_Version => new EntityMetadataPalette1194(), // 1.19.4 - 1.20.4
|
||||
<= Protocol18Handler.MC_1_21_Version => new EntityMetadataPalette1206(), // 1.20.6 - 1.21
|
||||
<= Protocol18Handler.MC_1_21_2_Version => new EntityMetadataPalette1206(), // 1.20.6 - 1.21.2
|
||||
_ => throw new NotImplementedException()
|
||||
};
|
||||
}
|
||||
|
|
|
|||
168
MinecraftClient/Mapping/EntityPalettes/EntityPalette1212.cs
Normal file
168
MinecraftClient/Mapping/EntityPalettes/EntityPalette1212.cs
Normal file
|
|
@ -0,0 +1,168 @@
|
|||
using System.Collections.Generic;
|
||||
|
||||
namespace MinecraftClient.Mapping.EntityPalettes
|
||||
{
|
||||
public class EntityPalette1212 : EntityPalette
|
||||
{
|
||||
private static readonly Dictionary<int, EntityType> mappings = new();
|
||||
|
||||
static EntityPalette1212()
|
||||
{
|
||||
mappings[0] = EntityType.AcaciaBoat;
|
||||
mappings[1] = EntityType.AcaciaChestBoat;
|
||||
mappings[2] = EntityType.Allay;
|
||||
mappings[3] = EntityType.AreaEffectCloud;
|
||||
mappings[4] = EntityType.Armadillo;
|
||||
mappings[5] = EntityType.ArmorStand;
|
||||
mappings[6] = EntityType.Arrow;
|
||||
mappings[7] = EntityType.Axolotl;
|
||||
mappings[8] = EntityType.BambooChestRaft;
|
||||
mappings[9] = EntityType.BambooRaft;
|
||||
mappings[10] = EntityType.Bat;
|
||||
mappings[11] = EntityType.Bee;
|
||||
mappings[12] = EntityType.BirchBoat;
|
||||
mappings[13] = EntityType.BirchChestBoat;
|
||||
mappings[14] = EntityType.Blaze;
|
||||
mappings[15] = EntityType.BlockDisplay;
|
||||
mappings[16] = EntityType.Bogged;
|
||||
mappings[17] = EntityType.Breeze;
|
||||
mappings[18] = EntityType.BreezeWindCharge;
|
||||
mappings[19] = EntityType.Camel;
|
||||
mappings[20] = EntityType.Cat;
|
||||
mappings[21] = EntityType.CaveSpider;
|
||||
mappings[22] = EntityType.CherryBoat;
|
||||
mappings[23] = EntityType.CherryChestBoat;
|
||||
mappings[24] = EntityType.ChestMinecart;
|
||||
mappings[25] = EntityType.Chicken;
|
||||
mappings[26] = EntityType.Cod;
|
||||
mappings[27] = EntityType.CommandBlockMinecart;
|
||||
mappings[28] = EntityType.Cow;
|
||||
mappings[29] = EntityType.Creaking;
|
||||
mappings[30] = EntityType.CreakingTransient;
|
||||
mappings[31] = EntityType.Creeper;
|
||||
mappings[32] = EntityType.DarkOakBoat;
|
||||
mappings[33] = EntityType.DarkOakChestBoat;
|
||||
mappings[34] = EntityType.Dolphin;
|
||||
mappings[35] = EntityType.Donkey;
|
||||
mappings[36] = EntityType.DragonFireball;
|
||||
mappings[37] = EntityType.Drowned;
|
||||
mappings[38] = EntityType.Egg;
|
||||
mappings[39] = EntityType.ElderGuardian;
|
||||
mappings[40] = EntityType.Enderman;
|
||||
mappings[41] = EntityType.Endermite;
|
||||
mappings[42] = EntityType.EnderDragon;
|
||||
mappings[43] = EntityType.EnderPearl;
|
||||
mappings[44] = EntityType.EndCrystal;
|
||||
mappings[45] = EntityType.Evoker;
|
||||
mappings[46] = EntityType.EvokerFangs;
|
||||
mappings[47] = EntityType.ExperienceBottle;
|
||||
mappings[48] = EntityType.ExperienceOrb;
|
||||
mappings[49] = EntityType.EyeOfEnder;
|
||||
mappings[50] = EntityType.FallingBlock;
|
||||
mappings[51] = EntityType.Fireball;
|
||||
mappings[52] = EntityType.FireworkRocket;
|
||||
mappings[53] = EntityType.Fox;
|
||||
mappings[54] = EntityType.Frog;
|
||||
mappings[55] = EntityType.FurnaceMinecart;
|
||||
mappings[56] = EntityType.Ghast;
|
||||
mappings[57] = EntityType.Giant;
|
||||
mappings[58] = EntityType.GlowItemFrame;
|
||||
mappings[59] = EntityType.GlowSquid;
|
||||
mappings[60] = EntityType.Goat;
|
||||
mappings[61] = EntityType.Guardian;
|
||||
mappings[62] = EntityType.Hoglin;
|
||||
mappings[63] = EntityType.HopperMinecart;
|
||||
mappings[64] = EntityType.Horse;
|
||||
mappings[65] = EntityType.Husk;
|
||||
mappings[66] = EntityType.Illusioner;
|
||||
mappings[67] = EntityType.Interaction;
|
||||
mappings[68] = EntityType.IronGolem;
|
||||
mappings[69] = EntityType.Item;
|
||||
mappings[70] = EntityType.ItemDisplay;
|
||||
mappings[71] = EntityType.ItemFrame;
|
||||
mappings[72] = EntityType.JungleBoat;
|
||||
mappings[73] = EntityType.JungleChestBoat;
|
||||
mappings[74] = EntityType.LeashKnot;
|
||||
mappings[75] = EntityType.LightningBolt;
|
||||
mappings[76] = EntityType.Llama;
|
||||
mappings[77] = EntityType.LlamaSpit;
|
||||
mappings[78] = EntityType.MagmaCube;
|
||||
mappings[79] = EntityType.MangroveBoat;
|
||||
mappings[80] = EntityType.MangroveChestBoat;
|
||||
mappings[81] = EntityType.Marker;
|
||||
mappings[82] = EntityType.Minecart;
|
||||
mappings[83] = EntityType.Mooshroom;
|
||||
mappings[84] = EntityType.Mule;
|
||||
mappings[85] = EntityType.OakBoat;
|
||||
mappings[86] = EntityType.OakChestBoat;
|
||||
mappings[87] = EntityType.Ocelot;
|
||||
mappings[88] = EntityType.OminousItemSpawner;
|
||||
mappings[89] = EntityType.Painting;
|
||||
mappings[90] = EntityType.PaleOakBoat;
|
||||
mappings[91] = EntityType.PaleOakChestBoat;
|
||||
mappings[92] = EntityType.Panda;
|
||||
mappings[93] = EntityType.Parrot;
|
||||
mappings[94] = EntityType.Phantom;
|
||||
mappings[95] = EntityType.Pig;
|
||||
mappings[96] = EntityType.Piglin;
|
||||
mappings[97] = EntityType.PiglinBrute;
|
||||
mappings[98] = EntityType.Pillager;
|
||||
mappings[99] = EntityType.PolarBear;
|
||||
mappings[100] = EntityType.Potion;
|
||||
mappings[101] = EntityType.Pufferfish;
|
||||
mappings[102] = EntityType.Rabbit;
|
||||
mappings[103] = EntityType.Ravager;
|
||||
mappings[104] = EntityType.Salmon;
|
||||
mappings[105] = EntityType.Sheep;
|
||||
mappings[106] = EntityType.Shulker;
|
||||
mappings[107] = EntityType.ShulkerBullet;
|
||||
mappings[108] = EntityType.Silverfish;
|
||||
mappings[109] = EntityType.Skeleton;
|
||||
mappings[110] = EntityType.SkeletonHorse;
|
||||
mappings[111] = EntityType.Slime;
|
||||
mappings[112] = EntityType.SmallFireball;
|
||||
mappings[113] = EntityType.Sniffer;
|
||||
mappings[114] = EntityType.Snowball;
|
||||
mappings[115] = EntityType.SnowGolem;
|
||||
mappings[116] = EntityType.SpawnerMinecart;
|
||||
mappings[117] = EntityType.SpectralArrow;
|
||||
mappings[118] = EntityType.Spider;
|
||||
mappings[119] = EntityType.SpruceBoat;
|
||||
mappings[120] = EntityType.SpruceChestBoat;
|
||||
mappings[121] = EntityType.Squid;
|
||||
mappings[122] = EntityType.Stray;
|
||||
mappings[123] = EntityType.Strider;
|
||||
mappings[124] = EntityType.Tadpole;
|
||||
mappings[125] = EntityType.TextDisplay;
|
||||
mappings[126] = EntityType.Tnt;
|
||||
mappings[127] = EntityType.TntMinecart;
|
||||
mappings[128] = EntityType.TraderLlama;
|
||||
mappings[129] = EntityType.Trident;
|
||||
mappings[130] = EntityType.TropicalFish;
|
||||
mappings[131] = EntityType.Turtle;
|
||||
mappings[132] = EntityType.Vex;
|
||||
mappings[133] = EntityType.Villager;
|
||||
mappings[134] = EntityType.Vindicator;
|
||||
mappings[135] = EntityType.WanderingTrader;
|
||||
mappings[136] = EntityType.Warden;
|
||||
mappings[137] = EntityType.WindCharge;
|
||||
mappings[138] = EntityType.Witch;
|
||||
mappings[139] = EntityType.Wither;
|
||||
mappings[140] = EntityType.WitherSkeleton;
|
||||
mappings[141] = EntityType.WitherSkull;
|
||||
mappings[142] = EntityType.Wolf;
|
||||
mappings[143] = EntityType.Zoglin;
|
||||
mappings[144] = EntityType.Zombie;
|
||||
mappings[145] = EntityType.ZombieHorse;
|
||||
mappings[146] = EntityType.ZombieVillager;
|
||||
mappings[147] = EntityType.ZombifiedPiglin;
|
||||
mappings[148] = EntityType.Player;
|
||||
mappings[149] = EntityType.FishingBobber;
|
||||
}
|
||||
|
||||
protected override Dictionary<int, EntityType> GetDict()
|
||||
{
|
||||
return mappings;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
namespace MinecraftClient.Mapping
|
||||
namespace MinecraftClient.Mapping
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents Minecraft Entity Types
|
||||
|
|
@ -14,14 +14,20 @@
|
|||
/// </remarks>
|
||||
public enum EntityType
|
||||
{
|
||||
AcaciaBoat,
|
||||
AcaciaChestBoat,
|
||||
Allay,
|
||||
AreaEffectCloud,
|
||||
Armadillo,
|
||||
ArmorStand,
|
||||
Arrow,
|
||||
Axolotl,
|
||||
BambooChestRaft,
|
||||
BambooRaft,
|
||||
Bat,
|
||||
Bee,
|
||||
BirchBoat,
|
||||
BirchChestBoat,
|
||||
Blaze,
|
||||
BlockDisplay,
|
||||
Boat,
|
||||
|
|
@ -31,13 +37,19 @@
|
|||
Camel,
|
||||
Cat,
|
||||
CaveSpider,
|
||||
CherryBoat,
|
||||
CherryChestBoat,
|
||||
ChestBoat,
|
||||
ChestMinecart,
|
||||
Chicken,
|
||||
Cod,
|
||||
CommandBlockMinecart,
|
||||
Cow,
|
||||
Creaking,
|
||||
CreakingTransient,
|
||||
Creeper,
|
||||
DarkOakBoat,
|
||||
DarkOakChestBoat,
|
||||
Dolphin,
|
||||
Donkey,
|
||||
DragonFireball,
|
||||
|
|
@ -77,18 +89,26 @@
|
|||
Item,
|
||||
ItemDisplay,
|
||||
ItemFrame,
|
||||
JungleBoat,
|
||||
JungleChestBoat,
|
||||
LeashKnot,
|
||||
LightningBolt,
|
||||
Llama,
|
||||
LlamaSpit,
|
||||
MagmaCube,
|
||||
MangroveBoat,
|
||||
MangroveChestBoat,
|
||||
Marker,
|
||||
Minecart,
|
||||
Mooshroom,
|
||||
Mule,
|
||||
OakBoat,
|
||||
OakChestBoat,
|
||||
Ocelot,
|
||||
OminousItemSpawner,
|
||||
Painting,
|
||||
PaleOakBoat,
|
||||
PaleOakChestBoat,
|
||||
Panda,
|
||||
Parrot,
|
||||
Phantom,
|
||||
|
|
@ -117,6 +137,8 @@
|
|||
SpawnerMinecart,
|
||||
SpectralArrow,
|
||||
Spider,
|
||||
SpruceBoat,
|
||||
SpruceChestBoat,
|
||||
Squid,
|
||||
Stray,
|
||||
Strider,
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
namespace MinecraftClient.Mapping
|
||||
namespace MinecraftClient.Mapping
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents Minecraft Materials
|
||||
|
|
@ -242,6 +242,7 @@
|
|||
CrackedStoneBricks,
|
||||
Crafter,
|
||||
CraftingTable,
|
||||
CreakingHeart,
|
||||
CreeperHead,
|
||||
CreeperWallHead,
|
||||
CrimsonButton,
|
||||
|
|
@ -662,6 +663,26 @@
|
|||
OxidizedCutCopperStairs,
|
||||
PackedIce,
|
||||
PackedMud,
|
||||
PaleHangingMoss,
|
||||
PaleMossBlock,
|
||||
PaleMossCarpet,
|
||||
PaleOakButton,
|
||||
PaleOakDoor,
|
||||
PaleOakFence,
|
||||
PaleOakFenceGate,
|
||||
PaleOakHangingSign,
|
||||
PaleOakLeaves,
|
||||
PaleOakLog,
|
||||
PaleOakPlanks,
|
||||
PaleOakPressurePlate,
|
||||
PaleOakSapling,
|
||||
PaleOakSign,
|
||||
PaleOakSlab,
|
||||
PaleOakStairs,
|
||||
PaleOakTrapdoor,
|
||||
PaleOakWallHangingSign,
|
||||
PaleOakWallSign,
|
||||
PaleOakWood,
|
||||
PearlescentFroglight,
|
||||
Peony,
|
||||
PetrifiedOakSlab,
|
||||
|
|
@ -745,6 +766,7 @@
|
|||
PottedOakSapling,
|
||||
PottedOrangeTulip,
|
||||
PottedOxeyeDaisy,
|
||||
PottedPaleOakSapling,
|
||||
PottedPinkTulip,
|
||||
PottedPoppy,
|
||||
PottedRedMushroom,
|
||||
|
|
@ -926,6 +948,8 @@
|
|||
StrippedMangroveWood,
|
||||
StrippedOakLog,
|
||||
StrippedOakWood,
|
||||
StrippedPaleOakLog,
|
||||
StrippedPaleOakWood,
|
||||
StrippedSpruceLog,
|
||||
StrippedSpruceWood,
|
||||
StrippedWarpedHyphae,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue