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
1393
MinecraftClient/Inventory/ItemPalettes/ItemPalette1212.cs
Normal file
1393
MinecraftClient/Inventory/ItemPalettes/ItemPalette1212.cs
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -121,6 +121,7 @@ namespace MinecraftClient.Inventory
|
|||
BlackStainedGlassPane,
|
||||
BlackTerracotta,
|
||||
BlackWool,
|
||||
BlackBundle,
|
||||
Blackstone,
|
||||
BlackstoneSlab,
|
||||
BlackstoneStairs,
|
||||
|
|
@ -145,6 +146,7 @@ namespace MinecraftClient.Inventory
|
|||
BlueStainedGlassPane,
|
||||
BlueTerracotta,
|
||||
BlueWool,
|
||||
BlueBundle,
|
||||
BoggedSpawnEgg,
|
||||
BoltArmorTrimSmithingTemplate,
|
||||
Bone,
|
||||
|
|
@ -152,6 +154,7 @@ namespace MinecraftClient.Inventory
|
|||
BoneMeal,
|
||||
Book,
|
||||
Bookshelf,
|
||||
BordureIndentedBannerPattern,
|
||||
Bow,
|
||||
Bowl,
|
||||
BrainCoral,
|
||||
|
|
@ -182,6 +185,7 @@ namespace MinecraftClient.Inventory
|
|||
BrownStainedGlassPane,
|
||||
BrownTerracotta,
|
||||
BrownWool,
|
||||
BrownBundle,
|
||||
Brush,
|
||||
BubbleCoral,
|
||||
BubbleCoralBlock,
|
||||
|
|
@ -298,6 +302,8 @@ namespace MinecraftClient.Inventory
|
|||
CrackedStoneBricks,
|
||||
Crafter,
|
||||
CraftingTable,
|
||||
CreakingHeart,
|
||||
CreakingSpawnEgg,
|
||||
CreeperBannerPattern,
|
||||
CreeperHead,
|
||||
CreeperSpawnEgg,
|
||||
|
|
@ -339,6 +345,7 @@ namespace MinecraftClient.Inventory
|
|||
CyanStainedGlassPane,
|
||||
CyanTerracotta,
|
||||
CyanWool,
|
||||
CyanBundle,
|
||||
DamagedAnvil,
|
||||
Dandelion,
|
||||
DangerPotterySherd,
|
||||
|
|
@ -472,6 +479,7 @@ namespace MinecraftClient.Inventory
|
|||
Feather,
|
||||
FermentedSpiderEye,
|
||||
Fern,
|
||||
FieldMasonedBannerPattern,
|
||||
FilledMap,
|
||||
FireCharge,
|
||||
FireCoral,
|
||||
|
|
@ -548,6 +556,7 @@ namespace MinecraftClient.Inventory
|
|||
GrayStainedGlassPane,
|
||||
GrayTerracotta,
|
||||
GrayWool,
|
||||
GrayBundle,
|
||||
GreenBanner,
|
||||
GreenBed,
|
||||
GreenCandle,
|
||||
|
|
@ -561,6 +570,7 @@ namespace MinecraftClient.Inventory
|
|||
GreenStainedGlassPane,
|
||||
GreenTerracotta,
|
||||
GreenWool,
|
||||
GreenBundle,
|
||||
Grindstone,
|
||||
GuardianSpawnEgg,
|
||||
Gunpowder,
|
||||
|
|
@ -668,6 +678,7 @@ namespace MinecraftClient.Inventory
|
|||
LightBlueStainedGlassPane,
|
||||
LightBlueTerracotta,
|
||||
LightBlueWool,
|
||||
LightBlueBundle,
|
||||
LightGrayBanner,
|
||||
LightGrayBed,
|
||||
LightGrayCandle,
|
||||
|
|
@ -681,6 +692,7 @@ namespace MinecraftClient.Inventory
|
|||
LightGrayStainedGlassPane,
|
||||
LightGrayTerracotta,
|
||||
LightGrayWool,
|
||||
LightGrayBundle,
|
||||
LightWeightedPressurePlate,
|
||||
LightningRod,
|
||||
Lilac,
|
||||
|
|
@ -699,6 +711,7 @@ namespace MinecraftClient.Inventory
|
|||
LimeStainedGlassPane,
|
||||
LimeTerracotta,
|
||||
LimeWool,
|
||||
LimeBundle,
|
||||
LingeringPotion,
|
||||
LlamaSpawnEgg,
|
||||
Lodestone,
|
||||
|
|
@ -717,6 +730,7 @@ namespace MinecraftClient.Inventory
|
|||
MagentaStainedGlassPane,
|
||||
MagentaTerracotta,
|
||||
MagentaWool,
|
||||
MagentaBundle,
|
||||
MagmaBlock,
|
||||
MagmaCream,
|
||||
MagmaCubeSpawnEgg,
|
||||
|
|
@ -855,6 +869,7 @@ namespace MinecraftClient.Inventory
|
|||
OrangeTerracotta,
|
||||
OrangeTulip,
|
||||
OrangeWool,
|
||||
OrangeBundle,
|
||||
OxeyeDaisy,
|
||||
OxidizedChiseledCopper,
|
||||
OxidizedCopper,
|
||||
|
|
@ -868,6 +883,26 @@ namespace MinecraftClient.Inventory
|
|||
PackedIce,
|
||||
PackedMud,
|
||||
Painting,
|
||||
PaleHangingMoss,
|
||||
PaleMossBlock,
|
||||
PaleMossCarpet,
|
||||
PaleOakBoat,
|
||||
PaleOakButton,
|
||||
PaleOakChestBoat,
|
||||
PaleOakDoor,
|
||||
PaleOakFence,
|
||||
PaleOakFenceGate,
|
||||
PaleOakHangingSign,
|
||||
PaleOakLeaves,
|
||||
PaleOakLog,
|
||||
PaleOakPlanks,
|
||||
PaleOakPressurePlate,
|
||||
PaleOakSapling,
|
||||
PaleOakSign,
|
||||
PaleOakSlab,
|
||||
PaleOakStairs,
|
||||
PaleOakTrapdoor,
|
||||
PaleOakWood,
|
||||
PandaSpawnEgg,
|
||||
Paper,
|
||||
ParrotSpawnEgg,
|
||||
|
|
@ -897,6 +932,7 @@ namespace MinecraftClient.Inventory
|
|||
PinkTerracotta,
|
||||
PinkTulip,
|
||||
PinkWool,
|
||||
PinkBundle,
|
||||
Piston,
|
||||
PitcherPlant,
|
||||
PitcherPod,
|
||||
|
|
@ -970,6 +1006,7 @@ namespace MinecraftClient.Inventory
|
|||
PurpleStainedGlassPane,
|
||||
PurpleTerracotta,
|
||||
PurpleWool,
|
||||
PurpleBundle,
|
||||
PurpurBlock,
|
||||
PurpurPillar,
|
||||
PurpurSlab,
|
||||
|
|
@ -1020,6 +1057,7 @@ namespace MinecraftClient.Inventory
|
|||
RedTerracotta,
|
||||
RedTulip,
|
||||
RedWool,
|
||||
RedBundle,
|
||||
Redstone,
|
||||
RedstoneBlock,
|
||||
RedstoneLamp,
|
||||
|
|
@ -1167,6 +1205,8 @@ namespace MinecraftClient.Inventory
|
|||
StrippedMangroveWood,
|
||||
StrippedOakLog,
|
||||
StrippedOakWood,
|
||||
StrippedPaleOakLog,
|
||||
StrippedPaleOakWood,
|
||||
StrippedSpruceLog,
|
||||
StrippedSpruceWood,
|
||||
StrippedWarpedHyphae,
|
||||
|
|
@ -1312,6 +1352,7 @@ namespace MinecraftClient.Inventory
|
|||
WhiteTerracotta,
|
||||
WhiteTulip,
|
||||
WhiteWool,
|
||||
WhiteBundle,
|
||||
WildArmorTrimSmithingTemplate,
|
||||
WindCharge,
|
||||
WitchSpawnEgg,
|
||||
|
|
@ -1341,6 +1382,7 @@ namespace MinecraftClient.Inventory
|
|||
YellowStainedGlassPane,
|
||||
YellowTerracotta,
|
||||
YellowWool,
|
||||
YellowBundle,
|
||||
ZoglinSpawnEgg,
|
||||
ZombieHead,
|
||||
ZombieHorseSpawnEgg,
|
||||
|
|
|
|||
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,
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ namespace MinecraftClient
|
|||
|
||||
public const string Version = MCHighestVersion;
|
||||
public const string MCLowestVersion = "1.4.6";
|
||||
public const string MCHighestVersion = "1.21";
|
||||
public const string MCHighestVersion = "1.21.2";
|
||||
public static readonly string? BuildInfo = null;
|
||||
|
||||
private static Tuple<Thread, CancellationTokenSource>? offlinePrompt = null;
|
||||
|
|
|
|||
|
|
@ -73,6 +73,7 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
internal const int MC_1_20_4_Version = 765;
|
||||
internal const int MC_1_20_6_Version = 766;
|
||||
internal const int MC_1_21_Version = 767;
|
||||
internal const int MC_1_21_2_Version = 768;
|
||||
|
||||
private int compression_treshold = -1;
|
||||
private int autocomplete_transaction_id = 0;
|
||||
|
|
@ -147,8 +148,9 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
Block.Palette = protocolVersion switch
|
||||
{
|
||||
// Block palette
|
||||
> MC_1_21_Version when handler.GetTerrainEnabled() =>
|
||||
> MC_1_21_2_Version when handler.GetTerrainEnabled() =>
|
||||
throw new NotImplementedException(Translations.exception_palette_block),
|
||||
>= MC_1_21_2_Version => new Palette1212(),
|
||||
>= MC_1_20_6_Version => new Palette1206(),
|
||||
>= MC_1_20_4_Version => new Palette1204(),
|
||||
>= MC_1_20_Version => new Palette120(),
|
||||
|
|
@ -166,8 +168,9 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
entityPalette = protocolVersion switch
|
||||
{
|
||||
// Entity palette
|
||||
> MC_1_21_Version when handler.GetEntityHandlingEnabled() =>
|
||||
> MC_1_21_2_Version when handler.GetEntityHandlingEnabled() =>
|
||||
throw new NotImplementedException(Translations.exception_palette_entity),
|
||||
>= MC_1_21_2_Version => new EntityPalette1212(),
|
||||
>= MC_1_20_6_Version => new EntityPalette1206(),
|
||||
>= MC_1_20_4_Version => new EntityPalette1204(),
|
||||
>= MC_1_20_Version => new EntityPalette120(),
|
||||
|
|
@ -189,8 +192,9 @@ namespace MinecraftClient.Protocol.Handlers
|
|||
itemPalette = protocolVersion switch
|
||||
{
|
||||
// Item palette
|
||||
> MC_1_21_Version when handler.GetInventoryEnabled() =>
|
||||
> MC_1_21_2_Version when handler.GetInventoryEnabled() =>
|
||||
throw new NotImplementedException(Translations.exception_palette_item),
|
||||
>= MC_1_21_2_Version => new ItemPalette1212(),
|
||||
>= MC_1_21_Version => new ItemPalette121(),
|
||||
>= MC_1_20_6_Version => new ItemPalette1206(),
|
||||
>= MC_1_20_4_Version => new ItemPalette1204(),
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data.Odbc;
|
||||
using System.Globalization;
|
||||
|
|
@ -153,7 +153,7 @@ namespace MinecraftClient.Protocol
|
|||
int[] suppoertedVersionsProtocol18 =
|
||||
{
|
||||
4, 5, 47, 107, 108, 109, 110, 210, 315, 316, 335, 338, 340, 393, 401, 404, 477, 480, 485, 490, 498, 573,
|
||||
575, 578, 735, 736, 751, 753, 754, 755, 756, 757, 758, 759, 760, 761, 762, 763, 764, 765, 766, 767
|
||||
575, 578, 735, 736, 751, 753, 754, 755, 756, 757, 758, 759, 760, 761, 762, 763, 764, 765, 766, 767, 768
|
||||
};
|
||||
|
||||
if (Array.IndexOf(suppoertedVersionsProtocol18, protocolVersion) > -1)
|
||||
|
|
@ -351,6 +351,8 @@ namespace MinecraftClient.Protocol
|
|||
case "1.21":
|
||||
case "1.21.1":
|
||||
return 767;
|
||||
case "1.21.2":
|
||||
return 768;
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -432,6 +434,7 @@ namespace MinecraftClient.Protocol
|
|||
765 => "1.20.4",
|
||||
766 => "1.20.6",
|
||||
767 => "1.21",
|
||||
768 => "1.21.2",
|
||||
_ => "0.0"
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue