From d7310e477b2e8b47793784a3328bf5eb13b5100f Mon Sep 17 00:00:00 2001 From: Milutinke Date: Mon, 22 Aug 2022 19:46:30 +0200 Subject: [PATCH] Added Item, Entity, Block, Material Palettes for 1.19. Fixed SpawnEntity and disabled BlockChange packet on 1.19 to prevent crashing until it's fixed. Enabled Entity and Inventory handling. --- .../Inventory/ItemPalettes/ItemPalette115.cs | 2 +- .../Inventory/ItemPalettes/ItemPalette1161.cs | 2 +- .../Inventory/ItemPalettes/ItemPalette1162.cs | 2 +- .../Inventory/ItemPalettes/ItemPalette117.cs | 2 +- .../Inventory/ItemPalettes/ItemPalette118.cs | 2 +- .../Inventory/ItemPalettes/ItemPalette119.cs | 1171 +++++++++++++ MinecraftClient/Inventory/ItemType.cs | 62 +- .../Mapping/BlockPalettes/Palette113.cs | 2 +- .../Mapping/BlockPalettes/Palette114.cs | 2 +- .../Mapping/BlockPalettes/Palette115.cs | 2 +- .../Mapping/BlockPalettes/Palette116.cs | 2 +- .../Mapping/BlockPalettes/Palette117.cs | 2 +- .../Mapping/BlockPalettes/Palette119.cs | 1530 +++++++++++++++++ .../EntityPalettes/EntityPalette119.cs | 137 ++ MinecraftClient/Mapping/EntityType.cs | 15 +- MinecraftClient/Mapping/Material.cs | 93 +- MinecraftClient/Mapping/Material2Tool.cs | 2 +- MinecraftClient/Mapping/MaterialExtensions.cs | 2 +- .../Protocol/Handlers/DataTypes.cs | 8 +- .../Protocol/Handlers/Protocol18.cs | 339 ++-- 20 files changed, 3161 insertions(+), 218 deletions(-) create mode 100644 MinecraftClient/Inventory/ItemPalettes/ItemPalette119.cs create mode 100644 MinecraftClient/Mapping/BlockPalettes/Palette119.cs create mode 100644 MinecraftClient/Mapping/EntityPalettes/EntityPalette119.cs diff --git a/MinecraftClient/Inventory/ItemPalettes/ItemPalette115.cs b/MinecraftClient/Inventory/ItemPalettes/ItemPalette115.cs index 99331b85..d69e143f 100644 --- a/MinecraftClient/Inventory/ItemPalettes/ItemPalette115.cs +++ b/MinecraftClient/Inventory/ItemPalettes/ItemPalette115.cs @@ -335,7 +335,7 @@ namespace MinecraftClient.Inventory.ItemPalettes mappings[319] = ItemType.AcaciaStairs; mappings[320] = ItemType.DarkOakStairs; mappings[321] = ItemType.SlimeBlock; - mappings[322] = ItemType.GrassPath; + mappings[322] = ItemType.DirtPath; mappings[323] = ItemType.Sunflower; mappings[324] = ItemType.Lilac; mappings[325] = ItemType.RoseBush; diff --git a/MinecraftClient/Inventory/ItemPalettes/ItemPalette1161.cs b/MinecraftClient/Inventory/ItemPalettes/ItemPalette1161.cs index c077afb2..0b0504c2 100644 --- a/MinecraftClient/Inventory/ItemPalettes/ItemPalette1161.cs +++ b/MinecraftClient/Inventory/ItemPalettes/ItemPalette1161.cs @@ -385,7 +385,7 @@ namespace MinecraftClient.Inventory.ItemPalettes mappings[369] = ItemType.AcaciaStairs; mappings[370] = ItemType.DarkOakStairs; mappings[371] = ItemType.SlimeBlock; - mappings[372] = ItemType.GrassPath; + mappings[372] = ItemType.DirtPath; mappings[373] = ItemType.Sunflower; mappings[374] = ItemType.Lilac; mappings[375] = ItemType.RoseBush; diff --git a/MinecraftClient/Inventory/ItemPalettes/ItemPalette1162.cs b/MinecraftClient/Inventory/ItemPalettes/ItemPalette1162.cs index f9e75cdc..aa674f45 100644 --- a/MinecraftClient/Inventory/ItemPalettes/ItemPalette1162.cs +++ b/MinecraftClient/Inventory/ItemPalettes/ItemPalette1162.cs @@ -385,7 +385,7 @@ namespace MinecraftClient.Inventory.ItemPalettes mappings[369] = ItemType.AcaciaStairs; mappings[370] = ItemType.DarkOakStairs; mappings[371] = ItemType.SlimeBlock; - mappings[372] = ItemType.GrassPath; + mappings[372] = ItemType.DirtPath; mappings[373] = ItemType.Sunflower; mappings[374] = ItemType.Lilac; mappings[375] = ItemType.RoseBush; diff --git a/MinecraftClient/Inventory/ItemPalettes/ItemPalette117.cs b/MinecraftClient/Inventory/ItemPalettes/ItemPalette117.cs index e11312dd..35d903ab 100644 --- a/MinecraftClient/Inventory/ItemPalettes/ItemPalette117.cs +++ b/MinecraftClient/Inventory/ItemPalettes/ItemPalette117.cs @@ -402,7 +402,7 @@ namespace MinecraftClient.Inventory.ItemPalettes mappings[390] = ItemType.PackedIce; mappings[391] = ItemType.AcaciaStairs; mappings[392] = ItemType.DarkOakStairs; - mappings[393] = ItemType.GrassPath; + mappings[393] = ItemType.DirtPath; mappings[394] = ItemType.Sunflower; mappings[395] = ItemType.Lilac; mappings[396] = ItemType.RoseBush; diff --git a/MinecraftClient/Inventory/ItemPalettes/ItemPalette118.cs b/MinecraftClient/Inventory/ItemPalettes/ItemPalette118.cs index 0e4577eb..d8e1d61d 100644 --- a/MinecraftClient/Inventory/ItemPalettes/ItemPalette118.cs +++ b/MinecraftClient/Inventory/ItemPalettes/ItemPalette118.cs @@ -402,7 +402,7 @@ namespace MinecraftClient.Inventory.ItemPalettes mappings[390] = ItemType.PackedIce; mappings[391] = ItemType.AcaciaStairs; mappings[392] = ItemType.DarkOakStairs; - mappings[393] = ItemType.GrassPath; + mappings[393] = ItemType.DirtPath; mappings[394] = ItemType.Sunflower; mappings[395] = ItemType.Lilac; mappings[396] = ItemType.RoseBush; diff --git a/MinecraftClient/Inventory/ItemPalettes/ItemPalette119.cs b/MinecraftClient/Inventory/ItemPalettes/ItemPalette119.cs new file mode 100644 index 00000000..c0540f4a --- /dev/null +++ b/MinecraftClient/Inventory/ItemPalettes/ItemPalette119.cs @@ -0,0 +1,1171 @@ +using System; +using System.Collections.Generic; + +namespace MinecraftClient.Inventory.ItemPalettes +{ + public class ItemPalette119 : ItemPalette + { + private static Dictionary mappings = new Dictionary(); + + static ItemPalette119() + { + mappings[706] = ItemType.AcaciaBoat; + mappings[638] = ItemType.AcaciaButton; + mappings[707] = ItemType.AcaciaChestBoat; + mappings[661] = ItemType.AcaciaDoor; + mappings[272] = ItemType.AcaciaFence; + mappings[680] = ItemType.AcaciaFenceGate; + mappings[146] = ItemType.AcaciaLeaves; + mappings[108] = ItemType.AcaciaLog; + mappings[27] = ItemType.AcaciaPlanks; + mappings[651] = ItemType.AcaciaPressurePlate; + mappings[36] = ItemType.AcaciaSapling; + mappings[808] = ItemType.AcaciaSign; + mappings[218] = ItemType.AcaciaSlab; + mappings[342] = ItemType.AcaciaStairs; + mappings[671] = ItemType.AcaciaTrapdoor; + mappings[137] = ItemType.AcaciaWood; + mappings[688] = ItemType.ActivatorRail; + mappings[0] = ItemType.Air; + mappings[912] = ItemType.AllaySpawnEgg; + mappings[186] = ItemType.Allium; + mappings[66] = ItemType.AmethystBlock; + mappings[1145] = ItemType.AmethystCluster; + mappings[726] = ItemType.AmethystShard; + mappings[61] = ItemType.AncientDebris; + mappings[6] = ItemType.Andesite; + mappings[599] = ItemType.AndesiteSlab; + mappings[582] = ItemType.AndesiteStairs; + mappings[359] = ItemType.AndesiteWall; + mappings[371] = ItemType.Anvil; + mappings[717] = ItemType.Apple; + mappings[1015] = ItemType.ArmorStand; + mappings[719] = ItemType.Arrow; + mappings[824] = ItemType.AxolotlBucket; + mappings[913] = ItemType.AxolotlSpawnEgg; + mappings[162] = ItemType.Azalea; + mappings[149] = ItemType.AzaleaLeaves; + mappings[187] = ItemType.AzureBluet; + mappings[992] = ItemType.BakedPotato; + mappings[213] = ItemType.Bamboo; + mappings[1089] = ItemType.Barrel; + mappings[395] = ItemType.Barrier; + mappings[283] = ItemType.Basalt; + mappings[914] = ItemType.BatSpawnEgg; + mappings[348] = ItemType.Beacon; + mappings[39] = ItemType.Bedrock; + mappings[1106] = ItemType.BeeNest; + mappings[915] = ItemType.BeeSpawnEgg; + mappings[892] = ItemType.Beef; + mappings[1107] = ItemType.Beehive; + mappings[1044] = ItemType.Beetroot; + mappings[1045] = ItemType.BeetrootSeeds; + mappings[1046] = ItemType.BeetrootSoup; + mappings[1097] = ItemType.Bell; + mappings[211] = ItemType.BigDripleaf; + mappings[702] = ItemType.BirchBoat; + mappings[636] = ItemType.BirchButton; + mappings[703] = ItemType.BirchChestBoat; + mappings[659] = ItemType.BirchDoor; + mappings[270] = ItemType.BirchFence; + mappings[678] = ItemType.BirchFenceGate; + mappings[144] = ItemType.BirchLeaves; + mappings[106] = ItemType.BirchLog; + mappings[25] = ItemType.BirchPlanks; + mappings[649] = ItemType.BirchPressurePlate; + mappings[34] = ItemType.BirchSapling; + mappings[806] = ItemType.BirchSign; + mappings[216] = ItemType.BirchSlab; + mappings[340] = ItemType.BirchStairs; + mappings[669] = ItemType.BirchTrapdoor; + mappings[135] = ItemType.BirchWood; + mappings[1040] = ItemType.BlackBanner; + mappings[884] = ItemType.BlackBed; + mappings[1141] = ItemType.BlackCandle; + mappings[413] = ItemType.BlackCarpet; + mappings[522] = ItemType.BlackConcrete; + mappings[538] = ItemType.BlackConcretePowder; + mappings[864] = ItemType.BlackDye; + mappings[506] = ItemType.BlackGlazedTerracotta; + mappings[490] = ItemType.BlackShulkerBox; + mappings[438] = ItemType.BlackStainedGlass; + mappings[454] = ItemType.BlackStainedGlassPane; + mappings[394] = ItemType.BlackTerracotta; + mappings[182] = ItemType.BlackWool; + mappings[1112] = ItemType.Blackstone; + mappings[1113] = ItemType.BlackstoneSlab; + mappings[1114] = ItemType.BlackstoneStairs; + mappings[364] = ItemType.BlackstoneWall; + mappings[1091] = ItemType.BlastFurnace; + mappings[906] = ItemType.BlazePowder; + mappings[898] = ItemType.BlazeRod; + mappings[916] = ItemType.BlazeSpawnEgg; + mappings[1036] = ItemType.BlueBanner; + mappings[880] = ItemType.BlueBed; + mappings[1137] = ItemType.BlueCandle; + mappings[409] = ItemType.BlueCarpet; + mappings[518] = ItemType.BlueConcrete; + mappings[534] = ItemType.BlueConcretePowder; + mappings[860] = ItemType.BlueDye; + mappings[502] = ItemType.BlueGlazedTerracotta; + mappings[570] = ItemType.BlueIce; + mappings[185] = ItemType.BlueOrchid; + mappings[486] = ItemType.BlueShulkerBox; + mappings[434] = ItemType.BlueStainedGlass; + mappings[450] = ItemType.BlueStainedGlassPane; + mappings[390] = ItemType.BlueTerracotta; + mappings[178] = ItemType.BlueWool; + mappings[866] = ItemType.Bone; + mappings[472] = ItemType.BoneBlock; + mappings[865] = ItemType.BoneMeal; + mappings[830] = ItemType.Book; + mappings[245] = ItemType.Bookshelf; + mappings[718] = ItemType.Bow; + mappings[766] = ItemType.Bowl; + mappings[551] = ItemType.BrainCoral; + mappings[546] = ItemType.BrainCoralBlock; + mappings[561] = ItemType.BrainCoralFan; + mappings[773] = ItemType.Bread; + mappings[908] = ItemType.BrewingStand; + mappings[826] = ItemType.Brick; + mappings[229] = ItemType.BrickSlab; + mappings[316] = ItemType.BrickStairs; + mappings[351] = ItemType.BrickWall; + mappings[244] = ItemType.Bricks; + mappings[1037] = ItemType.BrownBanner; + mappings[881] = ItemType.BrownBed; + mappings[1138] = ItemType.BrownCandle; + mappings[410] = ItemType.BrownCarpet; + mappings[519] = ItemType.BrownConcrete; + mappings[535] = ItemType.BrownConcretePowder; + mappings[861] = ItemType.BrownDye; + mappings[503] = ItemType.BrownGlazedTerracotta; + mappings[197] = ItemType.BrownMushroom; + mappings[307] = ItemType.BrownMushroomBlock; + mappings[487] = ItemType.BrownShulkerBox; + mappings[435] = ItemType.BrownStainedGlass; + mappings[451] = ItemType.BrownStainedGlassPane; + mappings[391] = ItemType.BrownTerracotta; + mappings[179] = ItemType.BrownWool; + mappings[552] = ItemType.BubbleCoral; + mappings[547] = ItemType.BubbleCoralBlock; + mappings[562] = ItemType.BubbleCoralFan; + mappings[813] = ItemType.Bucket; + mappings[67] = ItemType.BuddingAmethyst; + mappings[835] = ItemType.Bundle; + mappings[265] = ItemType.Cactus; + mappings[868] = ItemType.Cake; + mappings[11] = ItemType.Calcite; + mappings[1102] = ItemType.Campfire; + mappings[1125] = ItemType.Candle; + mappings[990] = ItemType.Carrot; + mappings[695] = ItemType.CarrotOnAStick; + mappings[1092] = ItemType.CartographyTable; + mappings[278] = ItemType.CarvedPumpkin; + mappings[917] = ItemType.CatSpawnEgg; + mappings[909] = ItemType.Cauldron; + mappings[918] = ItemType.CaveSpiderSpawnEgg; + mappings[311] = ItemType.Chain; + mappings[467] = ItemType.ChainCommandBlock; + mappings[781] = ItemType.ChainmailBoots; + mappings[779] = ItemType.ChainmailChestplate; + mappings[778] = ItemType.ChainmailHelmet; + mappings[780] = ItemType.ChainmailLeggings; + mappings[721] = ItemType.Charcoal; + mappings[256] = ItemType.Chest; + mappings[691] = ItemType.ChestMinecart; + mappings[894] = ItemType.Chicken; + mappings[919] = ItemType.ChickenSpawnEgg; + mappings[372] = ItemType.ChippedAnvil; + mappings[305] = ItemType.ChiseledDeepslate; + mappings[323] = ItemType.ChiseledNetherBricks; + mappings[1119] = ItemType.ChiseledPolishedBlackstone; + mappings[374] = ItemType.ChiseledQuartzBlock; + mappings[463] = ItemType.ChiseledRedSandstone; + mappings[157] = ItemType.ChiseledSandstone; + mappings[298] = ItemType.ChiseledStoneBricks; + mappings[251] = ItemType.ChorusFlower; + mappings[1042] = ItemType.ChorusFruit; + mappings[250] = ItemType.ChorusPlant; + mappings[266] = ItemType.Clay; + mappings[827] = ItemType.ClayBall; + mappings[837] = ItemType.Clock; + mappings[720] = ItemType.Coal; + mappings[62] = ItemType.CoalBlock; + mappings[43] = ItemType.CoalOre; + mappings[16] = ItemType.CoarseDirt; + mappings[9] = ItemType.CobbledDeepslate; + mappings[603] = ItemType.CobbledDeepslateSlab; + mappings[586] = ItemType.CobbledDeepslateStairs; + mappings[367] = ItemType.CobbledDeepslateWall; + mappings[22] = ItemType.Cobblestone; + mappings[228] = ItemType.CobblestoneSlab; + mappings[261] = ItemType.CobblestoneStairs; + mappings[349] = ItemType.CobblestoneWall; + mappings[159] = ItemType.Cobweb; + mappings[848] = ItemType.CocoaBeans; + mappings[840] = ItemType.Cod; + mappings[822] = ItemType.CodBucket; + mappings[920] = ItemType.CodSpawnEgg; + mappings[347] = ItemType.CommandBlock; + mappings[1022] = ItemType.CommandBlockMinecart; + mappings[612] = ItemType.Comparator; + mappings[833] = ItemType.Compass; + mappings[1088] = ItemType.Composter; + mappings[571] = ItemType.Conduit; + mappings[893] = ItemType.CookedBeef; + mappings[895] = ItemType.CookedChicken; + mappings[844] = ItemType.CookedCod; + mappings[1024] = ItemType.CookedMutton; + mappings[800] = ItemType.CookedPorkchop; + mappings[1011] = ItemType.CookedRabbit; + mappings[845] = ItemType.CookedSalmon; + mappings[885] = ItemType.Cookie; + mappings[69] = ItemType.CopperBlock; + mappings[730] = ItemType.CopperIngot; + mappings[47] = ItemType.CopperOre; + mappings[193] = ItemType.Cornflower; + mappings[921] = ItemType.CowSpawnEgg; + mappings[302] = ItemType.CrackedDeepslateBricks; + mappings[304] = ItemType.CrackedDeepslateTiles; + mappings[322] = ItemType.CrackedNetherBricks; + mappings[1123] = ItemType.CrackedPolishedBlackstoneBricks; + mappings[297] = ItemType.CrackedStoneBricks; + mappings[257] = ItemType.CraftingTable; + mappings[1082] = ItemType.CreeperBannerPattern; + mappings[1000] = ItemType.CreeperHead; + mappings[922] = ItemType.CreeperSpawnEgg; + mappings[641] = ItemType.CrimsonButton; + mappings[664] = ItemType.CrimsonDoor; + mappings[275] = ItemType.CrimsonFence; + mappings[683] = ItemType.CrimsonFenceGate; + mappings[199] = ItemType.CrimsonFungus; + mappings[140] = ItemType.CrimsonHyphae; + mappings[20] = ItemType.CrimsonNylium; + mappings[30] = ItemType.CrimsonPlanks; + mappings[654] = ItemType.CrimsonPressurePlate; + mappings[201] = ItemType.CrimsonRoots; + mappings[811] = ItemType.CrimsonSign; + mappings[221] = ItemType.CrimsonSlab; + mappings[345] = ItemType.CrimsonStairs; + mappings[113] = ItemType.CrimsonStem; + mappings[674] = ItemType.CrimsonTrapdoor; + mappings[1078] = ItemType.Crossbow; + mappings[1111] = ItemType.CryingObsidian; + mappings[76] = ItemType.CutCopper; + mappings[84] = ItemType.CutCopperSlab; + mappings[80] = ItemType.CutCopperStairs; + mappings[464] = ItemType.CutRedSandstone; + mappings[235] = ItemType.CutRedSandstoneSlab; + mappings[158] = ItemType.CutSandstone; + mappings[226] = ItemType.CutSandstoneSlab; + mappings[1034] = ItemType.CyanBanner; + mappings[878] = ItemType.CyanBed; + mappings[1135] = ItemType.CyanCandle; + mappings[407] = ItemType.CyanCarpet; + mappings[516] = ItemType.CyanConcrete; + mappings[532] = ItemType.CyanConcretePowder; + mappings[858] = ItemType.CyanDye; + mappings[500] = ItemType.CyanGlazedTerracotta; + mappings[484] = ItemType.CyanShulkerBox; + mappings[432] = ItemType.CyanStainedGlass; + mappings[448] = ItemType.CyanStainedGlassPane; + mappings[388] = ItemType.CyanTerracotta; + mappings[176] = ItemType.CyanWool; + mappings[373] = ItemType.DamagedAnvil; + mappings[183] = ItemType.Dandelion; + mappings[708] = ItemType.DarkOakBoat; + mappings[639] = ItemType.DarkOakButton; + mappings[709] = ItemType.DarkOakChestBoat; + mappings[662] = ItemType.DarkOakDoor; + mappings[273] = ItemType.DarkOakFence; + mappings[681] = ItemType.DarkOakFenceGate; + mappings[147] = ItemType.DarkOakLeaves; + mappings[109] = ItemType.DarkOakLog; + mappings[28] = ItemType.DarkOakPlanks; + mappings[652] = ItemType.DarkOakPressurePlate; + mappings[37] = ItemType.DarkOakSapling; + mappings[809] = ItemType.DarkOakSign; + mappings[219] = ItemType.DarkOakSlab; + mappings[343] = ItemType.DarkOakStairs; + mappings[672] = ItemType.DarkOakTrapdoor; + mappings[138] = ItemType.DarkOakWood; + mappings[457] = ItemType.DarkPrismarine; + mappings[239] = ItemType.DarkPrismarineSlab; + mappings[460] = ItemType.DarkPrismarineStairs; + mappings[625] = ItemType.DaylightDetector; + mappings[555] = ItemType.DeadBrainCoral; + mappings[541] = ItemType.DeadBrainCoralBlock; + mappings[566] = ItemType.DeadBrainCoralFan; + mappings[556] = ItemType.DeadBubbleCoral; + mappings[542] = ItemType.DeadBubbleCoralBlock; + mappings[567] = ItemType.DeadBubbleCoralFan; + mappings[164] = ItemType.DeadBush; + mappings[557] = ItemType.DeadFireCoral; + mappings[543] = ItemType.DeadFireCoralBlock; + mappings[568] = ItemType.DeadFireCoralFan; + mappings[558] = ItemType.DeadHornCoral; + mappings[544] = ItemType.DeadHornCoralBlock; + mappings[569] = ItemType.DeadHornCoralFan; + mappings[559] = ItemType.DeadTubeCoral; + mappings[540] = ItemType.DeadTubeCoralBlock; + mappings[565] = ItemType.DeadTubeCoralFan; + mappings[1057] = ItemType.DebugStick; + mappings[8] = ItemType.Deepslate; + mappings[605] = ItemType.DeepslateBrickSlab; + mappings[588] = ItemType.DeepslateBrickStairs; + mappings[369] = ItemType.DeepslateBrickWall; + mappings[301] = ItemType.DeepslateBricks; + mappings[44] = ItemType.DeepslateCoalOre; + mappings[48] = ItemType.DeepslateCopperOre; + mappings[58] = ItemType.DeepslateDiamondOre; + mappings[54] = ItemType.DeepslateEmeraldOre; + mappings[50] = ItemType.DeepslateGoldOre; + mappings[46] = ItemType.DeepslateIronOre; + mappings[56] = ItemType.DeepslateLapisOre; + mappings[52] = ItemType.DeepslateRedstoneOre; + mappings[606] = ItemType.DeepslateTileSlab; + mappings[589] = ItemType.DeepslateTileStairs; + mappings[370] = ItemType.DeepslateTileWall; + mappings[303] = ItemType.DeepslateTiles; + mappings[686] = ItemType.DetectorRail; + mappings[722] = ItemType.Diamond; + mappings[758] = ItemType.DiamondAxe; + mappings[71] = ItemType.DiamondBlock; + mappings[789] = ItemType.DiamondBoots; + mappings[787] = ItemType.DiamondChestplate; + mappings[786] = ItemType.DiamondHelmet; + mappings[759] = ItemType.DiamondHoe; + mappings[1018] = ItemType.DiamondHorseArmor; + mappings[788] = ItemType.DiamondLeggings; + mappings[57] = ItemType.DiamondOre; + mappings[757] = ItemType.DiamondPickaxe; + mappings[756] = ItemType.DiamondShovel; + mappings[755] = ItemType.DiamondSword; + mappings[4] = ItemType.Diorite; + mappings[602] = ItemType.DioriteSlab; + mappings[585] = ItemType.DioriteStairs; + mappings[363] = ItemType.DioriteWall; + mappings[15] = ItemType.Dirt; + mappings[416] = ItemType.DirtPath; + mappings[1073] = ItemType.DiscFragment5; + mappings[619] = ItemType.Dispenser; + mappings[923] = ItemType.DolphinSpawnEgg; + mappings[924] = ItemType.DonkeySpawnEgg; + mappings[1047] = ItemType.DragonBreath; + mappings[334] = ItemType.DragonEgg; + mappings[1001] = ItemType.DragonHead; + mappings[889] = ItemType.DriedKelp; + mappings[828] = ItemType.DriedKelpBlock; + mappings[13] = ItemType.DripstoneBlock; + mappings[620] = ItemType.Dropper; + mappings[925] = ItemType.DrownedSpawnEgg; + mappings[1151] = ItemType.EchoShard; + mappings[832] = ItemType.Egg; + mappings[926] = ItemType.ElderGuardianSpawnEgg; + mappings[697] = ItemType.Elytra; + mappings[723] = ItemType.Emerald; + mappings[337] = ItemType.EmeraldBlock; + mappings[53] = ItemType.EmeraldOre; + mappings[1006] = ItemType.EnchantedBook; + mappings[803] = ItemType.EnchantedGoldenApple; + mappings[330] = ItemType.EnchantingTable; + mappings[1041] = ItemType.EndCrystal; + mappings[331] = ItemType.EndPortalFrame; + mappings[249] = ItemType.EndRod; + mappings[332] = ItemType.EndStone; + mappings[595] = ItemType.EndStoneBrickSlab; + mappings[577] = ItemType.EndStoneBrickStairs; + mappings[362] = ItemType.EndStoneBrickWall; + mappings[333] = ItemType.EndStoneBricks; + mappings[336] = ItemType.EnderChest; + mappings[910] = ItemType.EnderEye; + mappings[897] = ItemType.EnderPearl; + mappings[927] = ItemType.EndermanSpawnEgg; + mappings[928] = ItemType.EndermiteSpawnEgg; + mappings[929] = ItemType.EvokerSpawnEgg; + mappings[983] = ItemType.ExperienceBottle; + mappings[73] = ItemType.ExposedCopper; + mappings[77] = ItemType.ExposedCutCopper; + mappings[85] = ItemType.ExposedCutCopperSlab; + mappings[81] = ItemType.ExposedCutCopperStairs; + mappings[258] = ItemType.Farmland; + mappings[769] = ItemType.Feather; + mappings[905] = ItemType.FermentedSpiderEye; + mappings[161] = ItemType.Fern; + mappings[886] = ItemType.FilledMap; + mappings[984] = ItemType.FireCharge; + mappings[553] = ItemType.FireCoral; + mappings[548] = ItemType.FireCoralBlock; + mappings[563] = ItemType.FireCoralFan; + mappings[1004] = ItemType.FireworkRocket; + mappings[1005] = ItemType.FireworkStar; + mappings[836] = ItemType.FishingRod; + mappings[1093] = ItemType.FletchingTable; + mappings[798] = ItemType.Flint; + mappings[716] = ItemType.FlintAndSteel; + mappings[1081] = ItemType.FlowerBannerPattern; + mappings[989] = ItemType.FlowerPot; + mappings[163] = ItemType.FloweringAzalea; + mappings[150] = ItemType.FloweringAzaleaLeaves; + mappings[930] = ItemType.FoxSpawnEgg; + mappings[931] = ItemType.FrogSpawnEgg; + mappings[1150] = ItemType.Frogspawn; + mappings[259] = ItemType.Furnace; + mappings[692] = ItemType.FurnaceMinecart; + mappings[932] = ItemType.GhastSpawnEgg; + mappings[899] = ItemType.GhastTear; + mappings[1115] = ItemType.GildedBlackstone; + mappings[153] = ItemType.Glass; + mappings[903] = ItemType.GlassBottle; + mappings[312] = ItemType.GlassPane; + mappings[911] = ItemType.GlisteringMelonSlice; + mappings[1085] = ItemType.GlobeBannerPattern; + mappings[1101] = ItemType.GlowBerries; + mappings[847] = ItemType.GlowInkSac; + mappings[988] = ItemType.GlowItemFrame; + mappings[315] = ItemType.GlowLichen; + mappings[933] = ItemType.GlowSquidSpawnEgg; + mappings[287] = ItemType.Glowstone; + mappings[839] = ItemType.GlowstoneDust; + mappings[1087] = ItemType.GoatHorn; + mappings[934] = ItemType.GoatSpawnEgg; + mappings[70] = ItemType.GoldBlock; + mappings[732] = ItemType.GoldIngot; + mappings[900] = ItemType.GoldNugget; + mappings[49] = ItemType.GoldOre; + mappings[802] = ItemType.GoldenApple; + mappings[748] = ItemType.GoldenAxe; + mappings[793] = ItemType.GoldenBoots; + mappings[995] = ItemType.GoldenCarrot; + mappings[791] = ItemType.GoldenChestplate; + mappings[790] = ItemType.GoldenHelmet; + mappings[749] = ItemType.GoldenHoe; + mappings[1017] = ItemType.GoldenHorseArmor; + mappings[792] = ItemType.GoldenLeggings; + mappings[747] = ItemType.GoldenPickaxe; + mappings[746] = ItemType.GoldenShovel; + mappings[745] = ItemType.GoldenSword; + mappings[2] = ItemType.Granite; + mappings[598] = ItemType.GraniteSlab; + mappings[581] = ItemType.GraniteStairs; + mappings[355] = ItemType.GraniteWall; + mappings[160] = ItemType.Grass; + mappings[14] = ItemType.GrassBlock; + mappings[42] = ItemType.Gravel; + mappings[1032] = ItemType.GrayBanner; + mappings[876] = ItemType.GrayBed; + mappings[1133] = ItemType.GrayCandle; + mappings[405] = ItemType.GrayCarpet; + mappings[514] = ItemType.GrayConcrete; + mappings[530] = ItemType.GrayConcretePowder; + mappings[856] = ItemType.GrayDye; + mappings[498] = ItemType.GrayGlazedTerracotta; + mappings[482] = ItemType.GrayShulkerBox; + mappings[430] = ItemType.GrayStainedGlass; + mappings[446] = ItemType.GrayStainedGlassPane; + mappings[386] = ItemType.GrayTerracotta; + mappings[174] = ItemType.GrayWool; + mappings[1038] = ItemType.GreenBanner; + mappings[882] = ItemType.GreenBed; + mappings[1139] = ItemType.GreenCandle; + mappings[411] = ItemType.GreenCarpet; + mappings[520] = ItemType.GreenConcrete; + mappings[536] = ItemType.GreenConcretePowder; + mappings[862] = ItemType.GreenDye; + mappings[504] = ItemType.GreenGlazedTerracotta; + mappings[488] = ItemType.GreenShulkerBox; + mappings[436] = ItemType.GreenStainedGlass; + mappings[452] = ItemType.GreenStainedGlassPane; + mappings[392] = ItemType.GreenTerracotta; + mappings[180] = ItemType.GreenWool; + mappings[1094] = ItemType.Grindstone; + mappings[935] = ItemType.GuardianSpawnEgg; + mappings[770] = ItemType.Gunpowder; + mappings[210] = ItemType.HangingRoots; + mappings[397] = ItemType.HayBlock; + mappings[1077] = ItemType.HeartOfTheSea; + mappings[646] = ItemType.HeavyWeightedPressurePlate; + mappings[936] = ItemType.HoglinSpawnEgg; + mappings[616] = ItemType.HoneyBlock; + mappings[1108] = ItemType.HoneyBottle; + mappings[1105] = ItemType.Honeycomb; + mappings[1109] = ItemType.HoneycombBlock; + mappings[618] = ItemType.Hopper; + mappings[694] = ItemType.HopperMinecart; + mappings[554] = ItemType.HornCoral; + mappings[549] = ItemType.HornCoralBlock; + mappings[564] = ItemType.HornCoralFan; + mappings[937] = ItemType.HorseSpawnEgg; + mappings[938] = ItemType.HuskSpawnEgg; + mappings[263] = ItemType.Ice; + mappings[293] = ItemType.InfestedChiseledStoneBricks; + mappings[289] = ItemType.InfestedCobblestone; + mappings[292] = ItemType.InfestedCrackedStoneBricks; + mappings[294] = ItemType.InfestedDeepslate; + mappings[291] = ItemType.InfestedMossyStoneBricks; + mappings[288] = ItemType.InfestedStone; + mappings[290] = ItemType.InfestedStoneBricks; + mappings[846] = ItemType.InkSac; + mappings[753] = ItemType.IronAxe; + mappings[310] = ItemType.IronBars; + mappings[68] = ItemType.IronBlock; + mappings[785] = ItemType.IronBoots; + mappings[783] = ItemType.IronChestplate; + mappings[656] = ItemType.IronDoor; + mappings[782] = ItemType.IronHelmet; + mappings[754] = ItemType.IronHoe; + mappings[1016] = ItemType.IronHorseArmor; + mappings[728] = ItemType.IronIngot; + mappings[784] = ItemType.IronLeggings; + mappings[1055] = ItemType.IronNugget; + mappings[45] = ItemType.IronOre; + mappings[752] = ItemType.IronPickaxe; + mappings[751] = ItemType.IronShovel; + mappings[750] = ItemType.IronSword; + mappings[666] = ItemType.IronTrapdoor; + mappings[987] = ItemType.ItemFrame; + mappings[279] = ItemType.JackOLantern; + mappings[713] = ItemType.Jigsaw; + mappings[267] = ItemType.Jukebox; + mappings[704] = ItemType.JungleBoat; + mappings[637] = ItemType.JungleButton; + mappings[705] = ItemType.JungleChestBoat; + mappings[660] = ItemType.JungleDoor; + mappings[271] = ItemType.JungleFence; + mappings[679] = ItemType.JungleFenceGate; + mappings[145] = ItemType.JungleLeaves; + mappings[107] = ItemType.JungleLog; + mappings[26] = ItemType.JunglePlanks; + mappings[650] = ItemType.JunglePressurePlate; + mappings[35] = ItemType.JungleSapling; + mappings[807] = ItemType.JungleSign; + mappings[217] = ItemType.JungleSlab; + mappings[341] = ItemType.JungleStairs; + mappings[670] = ItemType.JungleTrapdoor; + mappings[136] = ItemType.JungleWood; + mappings[207] = ItemType.Kelp; + mappings[1056] = ItemType.KnowledgeBook; + mappings[260] = ItemType.Ladder; + mappings[1098] = ItemType.Lantern; + mappings[155] = ItemType.LapisBlock; + mappings[724] = ItemType.LapisLazuli; + mappings[55] = ItemType.LapisOre; + mappings[1144] = ItemType.LargeAmethystBud; + mappings[422] = ItemType.LargeFern; + mappings[815] = ItemType.LavaBucket; + mappings[1020] = ItemType.Lead; + mappings[818] = ItemType.Leather; + mappings[777] = ItemType.LeatherBoots; + mappings[775] = ItemType.LeatherChestplate; + mappings[774] = ItemType.LeatherHelmet; + mappings[1019] = ItemType.LeatherHorseArmor; + mappings[776] = ItemType.LeatherLeggings; + mappings[621] = ItemType.Lectern; + mappings[623] = ItemType.Lever; + mappings[396] = ItemType.Light; + mappings[1028] = ItemType.LightBlueBanner; + mappings[872] = ItemType.LightBlueBed; + mappings[1129] = ItemType.LightBlueCandle; + mappings[401] = ItemType.LightBlueCarpet; + mappings[510] = ItemType.LightBlueConcrete; + mappings[526] = ItemType.LightBlueConcretePowder; + mappings[852] = ItemType.LightBlueDye; + mappings[494] = ItemType.LightBlueGlazedTerracotta; + mappings[478] = ItemType.LightBlueShulkerBox; + mappings[426] = ItemType.LightBlueStainedGlass; + mappings[442] = ItemType.LightBlueStainedGlassPane; + mappings[382] = ItemType.LightBlueTerracotta; + mappings[170] = ItemType.LightBlueWool; + mappings[1033] = ItemType.LightGrayBanner; + mappings[877] = ItemType.LightGrayBed; + mappings[1134] = ItemType.LightGrayCandle; + mappings[406] = ItemType.LightGrayCarpet; + mappings[515] = ItemType.LightGrayConcrete; + mappings[531] = ItemType.LightGrayConcretePowder; + mappings[857] = ItemType.LightGrayDye; + mappings[499] = ItemType.LightGrayGlazedTerracotta; + mappings[483] = ItemType.LightGrayShulkerBox; + mappings[431] = ItemType.LightGrayStainedGlass; + mappings[447] = ItemType.LightGrayStainedGlassPane; + mappings[387] = ItemType.LightGrayTerracotta; + mappings[175] = ItemType.LightGrayWool; + mappings[645] = ItemType.LightWeightedPressurePlate; + mappings[624] = ItemType.LightningRod; + mappings[418] = ItemType.Lilac; + mappings[194] = ItemType.LilyOfTheValley; + mappings[320] = ItemType.LilyPad; + mappings[1030] = ItemType.LimeBanner; + mappings[874] = ItemType.LimeBed; + mappings[1131] = ItemType.LimeCandle; + mappings[403] = ItemType.LimeCarpet; + mappings[512] = ItemType.LimeConcrete; + mappings[528] = ItemType.LimeConcretePowder; + mappings[854] = ItemType.LimeDye; + mappings[496] = ItemType.LimeGlazedTerracotta; + mappings[480] = ItemType.LimeShulkerBox; + mappings[428] = ItemType.LimeStainedGlass; + mappings[444] = ItemType.LimeStainedGlassPane; + mappings[384] = ItemType.LimeTerracotta; + mappings[172] = ItemType.LimeWool; + mappings[1051] = ItemType.LingeringPotion; + mappings[939] = ItemType.LlamaSpawnEgg; + mappings[1110] = ItemType.Lodestone; + mappings[1080] = ItemType.Loom; + mappings[1027] = ItemType.MagentaBanner; + mappings[871] = ItemType.MagentaBed; + mappings[1128] = ItemType.MagentaCandle; + mappings[400] = ItemType.MagentaCarpet; + mappings[509] = ItemType.MagentaConcrete; + mappings[525] = ItemType.MagentaConcretePowder; + mappings[851] = ItemType.MagentaDye; + mappings[493] = ItemType.MagentaGlazedTerracotta; + mappings[477] = ItemType.MagentaShulkerBox; + mappings[425] = ItemType.MagentaStainedGlass; + mappings[441] = ItemType.MagentaStainedGlassPane; + mappings[381] = ItemType.MagentaTerracotta; + mappings[169] = ItemType.MagentaWool; + mappings[468] = ItemType.MagmaBlock; + mappings[907] = ItemType.MagmaCream; + mappings[940] = ItemType.MagmaCubeSpawnEgg; + mappings[710] = ItemType.MangroveBoat; + mappings[640] = ItemType.MangroveButton; + mappings[711] = ItemType.MangroveChestBoat; + mappings[663] = ItemType.MangroveDoor; + mappings[274] = ItemType.MangroveFence; + mappings[682] = ItemType.MangroveFenceGate; + mappings[148] = ItemType.MangroveLeaves; + mappings[110] = ItemType.MangroveLog; + mappings[29] = ItemType.MangrovePlanks; + mappings[653] = ItemType.MangrovePressurePlate; + mappings[38] = ItemType.MangrovePropagule; + mappings[111] = ItemType.MangroveRoots; + mappings[810] = ItemType.MangroveSign; + mappings[220] = ItemType.MangroveSlab; + mappings[344] = ItemType.MangroveStairs; + mappings[673] = ItemType.MangroveTrapdoor; + mappings[139] = ItemType.MangroveWood; + mappings[994] = ItemType.Map; + mappings[1143] = ItemType.MediumAmethystBud; + mappings[313] = ItemType.Melon; + mappings[891] = ItemType.MelonSeeds; + mappings[888] = ItemType.MelonSlice; + mappings[819] = ItemType.MilkBucket; + mappings[690] = ItemType.Minecart; + mappings[1084] = ItemType.MojangBannerPattern; + mappings[941] = ItemType.MooshroomSpawnEgg; + mappings[209] = ItemType.MossBlock; + mappings[208] = ItemType.MossCarpet; + mappings[246] = ItemType.MossyCobblestone; + mappings[594] = ItemType.MossyCobblestoneSlab; + mappings[576] = ItemType.MossyCobblestoneStairs; + mappings[350] = ItemType.MossyCobblestoneWall; + mappings[592] = ItemType.MossyStoneBrickSlab; + mappings[574] = ItemType.MossyStoneBrickStairs; + mappings[354] = ItemType.MossyStoneBrickWall; + mappings[296] = ItemType.MossyStoneBricks; + mappings[19] = ItemType.Mud; + mappings[231] = ItemType.MudBrickSlab; + mappings[318] = ItemType.MudBrickStairs; + mappings[357] = ItemType.MudBrickWall; + mappings[300] = ItemType.MudBricks; + mappings[112] = ItemType.MuddyMangroveRoots; + mappings[942] = ItemType.MuleSpawnEgg; + mappings[309] = ItemType.MushroomStem; + mappings[767] = ItemType.MushroomStew; + mappings[1068] = ItemType.MusicDisc11; + mappings[1058] = ItemType.MusicDisc13; + mappings[1071] = ItemType.MusicDisc5; + mappings[1060] = ItemType.MusicDiscBlocks; + mappings[1059] = ItemType.MusicDiscCat; + mappings[1061] = ItemType.MusicDiscChirp; + mappings[1062] = ItemType.MusicDiscFar; + mappings[1063] = ItemType.MusicDiscMall; + mappings[1064] = ItemType.MusicDiscMellohi; + mappings[1070] = ItemType.MusicDiscOtherside; + mappings[1072] = ItemType.MusicDiscPigstep; + mappings[1065] = ItemType.MusicDiscStal; + mappings[1066] = ItemType.MusicDiscStrad; + mappings[1069] = ItemType.MusicDiscWait; + mappings[1067] = ItemType.MusicDiscWard; + mappings[1023] = ItemType.Mutton; + mappings[319] = ItemType.Mycelium; + mappings[1021] = ItemType.NameTag; + mappings[1076] = ItemType.NautilusShell; + mappings[1007] = ItemType.NetherBrick; + mappings[324] = ItemType.NetherBrickFence; + mappings[232] = ItemType.NetherBrickSlab; + mappings[325] = ItemType.NetherBrickStairs; + mappings[358] = ItemType.NetherBrickWall; + mappings[321] = ItemType.NetherBricks; + mappings[59] = ItemType.NetherGoldOre; + mappings[60] = ItemType.NetherQuartzOre; + mappings[203] = ItemType.NetherSprouts; + mappings[1002] = ItemType.NetherStar; + mappings[901] = ItemType.NetherWart; + mappings[469] = ItemType.NetherWartBlock; + mappings[763] = ItemType.NetheriteAxe; + mappings[72] = ItemType.NetheriteBlock; + mappings[797] = ItemType.NetheriteBoots; + mappings[795] = ItemType.NetheriteChestplate; + mappings[794] = ItemType.NetheriteHelmet; + mappings[764] = ItemType.NetheriteHoe; + mappings[733] = ItemType.NetheriteIngot; + mappings[796] = ItemType.NetheriteLeggings; + mappings[762] = ItemType.NetheritePickaxe; + mappings[734] = ItemType.NetheriteScrap; + mappings[761] = ItemType.NetheriteShovel; + mappings[760] = ItemType.NetheriteSword; + mappings[280] = ItemType.Netherrack; + mappings[631] = ItemType.NoteBlock; + mappings[698] = ItemType.OakBoat; + mappings[634] = ItemType.OakButton; + mappings[699] = ItemType.OakChestBoat; + mappings[657] = ItemType.OakDoor; + mappings[268] = ItemType.OakFence; + mappings[676] = ItemType.OakFenceGate; + mappings[142] = ItemType.OakLeaves; + mappings[104] = ItemType.OakLog; + mappings[23] = ItemType.OakPlanks; + mappings[647] = ItemType.OakPressurePlate; + mappings[32] = ItemType.OakSapling; + mappings[804] = ItemType.OakSign; + mappings[214] = ItemType.OakSlab; + mappings[338] = ItemType.OakStairs; + mappings[667] = ItemType.OakTrapdoor; + mappings[133] = ItemType.OakWood; + mappings[617] = ItemType.Observer; + mappings[247] = ItemType.Obsidian; + mappings[943] = ItemType.OcelotSpawnEgg; + mappings[1147] = ItemType.OchreFroglight; + mappings[1026] = ItemType.OrangeBanner; + mappings[870] = ItemType.OrangeBed; + mappings[1127] = ItemType.OrangeCandle; + mappings[399] = ItemType.OrangeCarpet; + mappings[508] = ItemType.OrangeConcrete; + mappings[524] = ItemType.OrangeConcretePowder; + mappings[850] = ItemType.OrangeDye; + mappings[492] = ItemType.OrangeGlazedTerracotta; + mappings[476] = ItemType.OrangeShulkerBox; + mappings[424] = ItemType.OrangeStainedGlass; + mappings[440] = ItemType.OrangeStainedGlassPane; + mappings[380] = ItemType.OrangeTerracotta; + mappings[189] = ItemType.OrangeTulip; + mappings[168] = ItemType.OrangeWool; + mappings[192] = ItemType.OxeyeDaisy; + mappings[75] = ItemType.OxidizedCopper; + mappings[79] = ItemType.OxidizedCutCopper; + mappings[87] = ItemType.OxidizedCutCopperSlab; + mappings[83] = ItemType.OxidizedCutCopperStairs; + mappings[415] = ItemType.PackedIce; + mappings[299] = ItemType.PackedMud; + mappings[801] = ItemType.Painting; + mappings[944] = ItemType.PandaSpawnEgg; + mappings[829] = ItemType.Paper; + mappings[945] = ItemType.ParrotSpawnEgg; + mappings[1149] = ItemType.PearlescentFroglight; + mappings[420] = ItemType.Peony; + mappings[227] = ItemType.PetrifiedOakSlab; + mappings[1075] = ItemType.PhantomMembrane; + mappings[946] = ItemType.PhantomSpawnEgg; + mappings[947] = ItemType.PigSpawnEgg; + mappings[1086] = ItemType.PiglinBannerPattern; + mappings[949] = ItemType.PiglinBruteSpawnEgg; + mappings[948] = ItemType.PiglinSpawnEgg; + mappings[950] = ItemType.PillagerSpawnEgg; + mappings[1031] = ItemType.PinkBanner; + mappings[875] = ItemType.PinkBed; + mappings[1132] = ItemType.PinkCandle; + mappings[404] = ItemType.PinkCarpet; + mappings[513] = ItemType.PinkConcrete; + mappings[529] = ItemType.PinkConcretePowder; + mappings[855] = ItemType.PinkDye; + mappings[497] = ItemType.PinkGlazedTerracotta; + mappings[481] = ItemType.PinkShulkerBox; + mappings[429] = ItemType.PinkStainedGlass; + mappings[445] = ItemType.PinkStainedGlassPane; + mappings[385] = ItemType.PinkTerracotta; + mappings[191] = ItemType.PinkTulip; + mappings[173] = ItemType.PinkWool; + mappings[613] = ItemType.Piston; + mappings[998] = ItemType.PlayerHead; + mappings[17] = ItemType.Podzol; + mappings[1146] = ItemType.PointedDripstone; + mappings[993] = ItemType.PoisonousPotato; + mappings[951] = ItemType.PolarBearSpawnEgg; + mappings[7] = ItemType.PolishedAndesite; + mappings[601] = ItemType.PolishedAndesiteSlab; + mappings[584] = ItemType.PolishedAndesiteStairs; + mappings[284] = ItemType.PolishedBasalt; + mappings[1116] = ItemType.PolishedBlackstone; + mappings[1121] = ItemType.PolishedBlackstoneBrickSlab; + mappings[1122] = ItemType.PolishedBlackstoneBrickStairs; + mappings[366] = ItemType.PolishedBlackstoneBrickWall; + mappings[1120] = ItemType.PolishedBlackstoneBricks; + mappings[633] = ItemType.PolishedBlackstoneButton; + mappings[644] = ItemType.PolishedBlackstonePressurePlate; + mappings[1117] = ItemType.PolishedBlackstoneSlab; + mappings[1118] = ItemType.PolishedBlackstoneStairs; + mappings[365] = ItemType.PolishedBlackstoneWall; + mappings[10] = ItemType.PolishedDeepslate; + mappings[604] = ItemType.PolishedDeepslateSlab; + mappings[587] = ItemType.PolishedDeepslateStairs; + mappings[368] = ItemType.PolishedDeepslateWall; + mappings[5] = ItemType.PolishedDiorite; + mappings[593] = ItemType.PolishedDioriteSlab; + mappings[575] = ItemType.PolishedDioriteStairs; + mappings[3] = ItemType.PolishedGranite; + mappings[590] = ItemType.PolishedGraniteSlab; + mappings[572] = ItemType.PolishedGraniteStairs; + mappings[1043] = ItemType.PoppedChorusFruit; + mappings[184] = ItemType.Poppy; + mappings[799] = ItemType.Porkchop; + mappings[991] = ItemType.Potato; + mappings[902] = ItemType.Potion; + mappings[816] = ItemType.PowderSnowBucket; + mappings[685] = ItemType.PoweredRail; + mappings[455] = ItemType.Prismarine; + mappings[238] = ItemType.PrismarineBrickSlab; + mappings[459] = ItemType.PrismarineBrickStairs; + mappings[456] = ItemType.PrismarineBricks; + mappings[1009] = ItemType.PrismarineCrystals; + mappings[1008] = ItemType.PrismarineShard; + mappings[237] = ItemType.PrismarineSlab; + mappings[458] = ItemType.PrismarineStairs; + mappings[352] = ItemType.PrismarineWall; + mappings[843] = ItemType.Pufferfish; + mappings[820] = ItemType.PufferfishBucket; + mappings[952] = ItemType.PufferfishSpawnEgg; + mappings[277] = ItemType.Pumpkin; + mappings[1003] = ItemType.PumpkinPie; + mappings[890] = ItemType.PumpkinSeeds; + mappings[1035] = ItemType.PurpleBanner; + mappings[879] = ItemType.PurpleBed; + mappings[1136] = ItemType.PurpleCandle; + mappings[408] = ItemType.PurpleCarpet; + mappings[517] = ItemType.PurpleConcrete; + mappings[533] = ItemType.PurpleConcretePowder; + mappings[859] = ItemType.PurpleDye; + mappings[501] = ItemType.PurpleGlazedTerracotta; + mappings[485] = ItemType.PurpleShulkerBox; + mappings[433] = ItemType.PurpleStainedGlass; + mappings[449] = ItemType.PurpleStainedGlassPane; + mappings[389] = ItemType.PurpleTerracotta; + mappings[177] = ItemType.PurpleWool; + mappings[252] = ItemType.PurpurBlock; + mappings[253] = ItemType.PurpurPillar; + mappings[236] = ItemType.PurpurSlab; + mappings[254] = ItemType.PurpurStairs; + mappings[725] = ItemType.Quartz; + mappings[375] = ItemType.QuartzBlock; + mappings[376] = ItemType.QuartzBricks; + mappings[377] = ItemType.QuartzPillar; + mappings[233] = ItemType.QuartzSlab; + mappings[378] = ItemType.QuartzStairs; + mappings[1010] = ItemType.Rabbit; + mappings[1013] = ItemType.RabbitFoot; + mappings[1014] = ItemType.RabbitHide; + mappings[953] = ItemType.RabbitSpawnEgg; + mappings[1012] = ItemType.RabbitStew; + mappings[687] = ItemType.Rail; + mappings[954] = ItemType.RavagerSpawnEgg; + mappings[729] = ItemType.RawCopper; + mappings[64] = ItemType.RawCopperBlock; + mappings[731] = ItemType.RawGold; + mappings[65] = ItemType.RawGoldBlock; + mappings[727] = ItemType.RawIron; + mappings[63] = ItemType.RawIronBlock; + mappings[834] = ItemType.RecoveryCompass; + mappings[1039] = ItemType.RedBanner; + mappings[883] = ItemType.RedBed; + mappings[1140] = ItemType.RedCandle; + mappings[412] = ItemType.RedCarpet; + mappings[521] = ItemType.RedConcrete; + mappings[537] = ItemType.RedConcretePowder; + mappings[863] = ItemType.RedDye; + mappings[505] = ItemType.RedGlazedTerracotta; + mappings[198] = ItemType.RedMushroom; + mappings[308] = ItemType.RedMushroomBlock; + mappings[600] = ItemType.RedNetherBrickSlab; + mappings[583] = ItemType.RedNetherBrickStairs; + mappings[360] = ItemType.RedNetherBrickWall; + mappings[471] = ItemType.RedNetherBricks; + mappings[41] = ItemType.RedSand; + mappings[462] = ItemType.RedSandstone; + mappings[234] = ItemType.RedSandstoneSlab; + mappings[465] = ItemType.RedSandstoneStairs; + mappings[353] = ItemType.RedSandstoneWall; + mappings[489] = ItemType.RedShulkerBox; + mappings[437] = ItemType.RedStainedGlass; + mappings[453] = ItemType.RedStainedGlassPane; + mappings[393] = ItemType.RedTerracotta; + mappings[188] = ItemType.RedTulip; + mappings[181] = ItemType.RedWool; + mappings[608] = ItemType.Redstone; + mappings[610] = ItemType.RedstoneBlock; + mappings[630] = ItemType.RedstoneLamp; + mappings[51] = ItemType.RedstoneOre; + mappings[609] = ItemType.RedstoneTorch; + mappings[306] = ItemType.ReinforcedDeepslate; + mappings[611] = ItemType.Repeater; + mappings[466] = ItemType.RepeatingCommandBlock; + mappings[1124] = ItemType.RespawnAnchor; + mappings[18] = ItemType.RootedDirt; + mappings[419] = ItemType.RoseBush; + mappings[896] = ItemType.RottenFlesh; + mappings[689] = ItemType.Saddle; + mappings[841] = ItemType.Salmon; + mappings[821] = ItemType.SalmonBucket; + mappings[955] = ItemType.SalmonSpawnEgg; + mappings[40] = ItemType.Sand; + mappings[156] = ItemType.Sandstone; + mappings[225] = ItemType.SandstoneSlab; + mappings[335] = ItemType.SandstoneStairs; + mappings[361] = ItemType.SandstoneWall; + mappings[607] = ItemType.Scaffolding; + mappings[326] = ItemType.Sculk; + mappings[328] = ItemType.SculkCatalyst; + mappings[626] = ItemType.SculkSensor; + mappings[329] = ItemType.SculkShrieker; + mappings[327] = ItemType.SculkVein; + mappings[715] = ItemType.Scute; + mappings[461] = ItemType.SeaLantern; + mappings[166] = ItemType.SeaPickle; + mappings[165] = ItemType.Seagrass; + mappings[887] = ItemType.Shears; + mappings[956] = ItemType.SheepSpawnEgg; + mappings[1052] = ItemType.Shield; + mappings[1104] = ItemType.Shroomlight; + mappings[474] = ItemType.ShulkerBox; + mappings[1054] = ItemType.ShulkerShell; + mappings[957] = ItemType.ShulkerSpawnEgg; + mappings[958] = ItemType.SilverfishSpawnEgg; + mappings[960] = ItemType.SkeletonHorseSpawnEgg; + mappings[996] = ItemType.SkeletonSkull; + mappings[959] = ItemType.SkeletonSpawnEgg; + mappings[1083] = ItemType.SkullBannerPattern; + mappings[831] = ItemType.SlimeBall; + mappings[615] = ItemType.SlimeBlock; + mappings[961] = ItemType.SlimeSpawnEgg; + mappings[1142] = ItemType.SmallAmethystBud; + mappings[212] = ItemType.SmallDripleaf; + mappings[1095] = ItemType.SmithingTable; + mappings[1090] = ItemType.Smoker; + mappings[285] = ItemType.SmoothBasalt; + mappings[240] = ItemType.SmoothQuartz; + mappings[597] = ItemType.SmoothQuartzSlab; + mappings[580] = ItemType.SmoothQuartzStairs; + mappings[241] = ItemType.SmoothRedSandstone; + mappings[591] = ItemType.SmoothRedSandstoneSlab; + mappings[573] = ItemType.SmoothRedSandstoneStairs; + mappings[242] = ItemType.SmoothSandstone; + mappings[596] = ItemType.SmoothSandstoneSlab; + mappings[579] = ItemType.SmoothSandstoneStairs; + mappings[243] = ItemType.SmoothStone; + mappings[224] = ItemType.SmoothStoneSlab; + mappings[262] = ItemType.Snow; + mappings[264] = ItemType.SnowBlock; + mappings[817] = ItemType.Snowball; + mappings[1103] = ItemType.SoulCampfire; + mappings[1099] = ItemType.SoulLantern; + mappings[281] = ItemType.SoulSand; + mappings[282] = ItemType.SoulSoil; + mappings[286] = ItemType.SoulTorch; + mappings[255] = ItemType.Spawner; + mappings[1049] = ItemType.SpectralArrow; + mappings[904] = ItemType.SpiderEye; + mappings[962] = ItemType.SpiderSpawnEgg; + mappings[1048] = ItemType.SplashPotion; + mappings[151] = ItemType.Sponge; + mappings[196] = ItemType.SporeBlossom; + mappings[700] = ItemType.SpruceBoat; + mappings[635] = ItemType.SpruceButton; + mappings[701] = ItemType.SpruceChestBoat; + mappings[658] = ItemType.SpruceDoor; + mappings[269] = ItemType.SpruceFence; + mappings[677] = ItemType.SpruceFenceGate; + mappings[143] = ItemType.SpruceLeaves; + mappings[105] = ItemType.SpruceLog; + mappings[24] = ItemType.SprucePlanks; + mappings[648] = ItemType.SprucePressurePlate; + mappings[33] = ItemType.SpruceSapling; + mappings[805] = ItemType.SpruceSign; + mappings[215] = ItemType.SpruceSlab; + mappings[339] = ItemType.SpruceStairs; + mappings[668] = ItemType.SpruceTrapdoor; + mappings[134] = ItemType.SpruceWood; + mappings[838] = ItemType.Spyglass; + mappings[963] = ItemType.SquidSpawnEgg; + mappings[765] = ItemType.Stick; + mappings[614] = ItemType.StickyPiston; + mappings[1] = ItemType.Stone; + mappings[743] = ItemType.StoneAxe; + mappings[230] = ItemType.StoneBrickSlab; + mappings[317] = ItemType.StoneBrickStairs; + mappings[356] = ItemType.StoneBrickWall; + mappings[295] = ItemType.StoneBricks; + mappings[632] = ItemType.StoneButton; + mappings[744] = ItemType.StoneHoe; + mappings[742] = ItemType.StonePickaxe; + mappings[643] = ItemType.StonePressurePlate; + mappings[741] = ItemType.StoneShovel; + mappings[223] = ItemType.StoneSlab; + mappings[578] = ItemType.StoneStairs; + mappings[740] = ItemType.StoneSword; + mappings[1096] = ItemType.Stonecutter; + mappings[964] = ItemType.StraySpawnEgg; + mappings[965] = ItemType.StriderSpawnEgg; + mappings[768] = ItemType.String; + mappings[119] = ItemType.StrippedAcaciaLog; + mappings[128] = ItemType.StrippedAcaciaWood; + mappings[117] = ItemType.StrippedBirchLog; + mappings[126] = ItemType.StrippedBirchWood; + mappings[131] = ItemType.StrippedCrimsonHyphae; + mappings[122] = ItemType.StrippedCrimsonStem; + mappings[120] = ItemType.StrippedDarkOakLog; + mappings[129] = ItemType.StrippedDarkOakWood; + mappings[118] = ItemType.StrippedJungleLog; + mappings[127] = ItemType.StrippedJungleWood; + mappings[121] = ItemType.StrippedMangroveLog; + mappings[130] = ItemType.StrippedMangroveWood; + mappings[115] = ItemType.StrippedOakLog; + mappings[124] = ItemType.StrippedOakWood; + mappings[116] = ItemType.StrippedSpruceLog; + mappings[125] = ItemType.StrippedSpruceWood; + mappings[132] = ItemType.StrippedWarpedHyphae; + mappings[123] = ItemType.StrippedWarpedStem; + mappings[712] = ItemType.StructureBlock; + mappings[473] = ItemType.StructureVoid; + mappings[867] = ItemType.Sugar; + mappings[206] = ItemType.SugarCane; + mappings[417] = ItemType.Sunflower; + mappings[1079] = ItemType.SuspiciousStew; + mappings[1100] = ItemType.SweetBerries; + mappings[825] = ItemType.TadpoleBucket; + mappings[966] = ItemType.TadpoleSpawnEgg; + mappings[421] = ItemType.TallGrass; + mappings[622] = ItemType.Target; + mappings[414] = ItemType.Terracotta; + mappings[154] = ItemType.TintedGlass; + mappings[1050] = ItemType.TippedArrow; + mappings[629] = ItemType.Tnt; + mappings[693] = ItemType.TntMinecart; + mappings[248] = ItemType.Torch; + mappings[1053] = ItemType.TotemOfUndying; + mappings[967] = ItemType.TraderLlamaSpawnEgg; + mappings[628] = ItemType.TrappedChest; + mappings[1074] = ItemType.Trident; + mappings[627] = ItemType.TripwireHook; + mappings[842] = ItemType.TropicalFish; + mappings[823] = ItemType.TropicalFishBucket; + mappings[968] = ItemType.TropicalFishSpawnEgg; + mappings[550] = ItemType.TubeCoral; + mappings[545] = ItemType.TubeCoralBlock; + mappings[560] = ItemType.TubeCoralFan; + mappings[12] = ItemType.Tuff; + mappings[539] = ItemType.TurtleEgg; + mappings[714] = ItemType.TurtleHelmet; + mappings[969] = ItemType.TurtleSpawnEgg; + mappings[205] = ItemType.TwistingVines; + mappings[1148] = ItemType.VerdantFroglight; + mappings[970] = ItemType.VexSpawnEgg; + mappings[971] = ItemType.VillagerSpawnEgg; + mappings[972] = ItemType.VindicatorSpawnEgg; + mappings[314] = ItemType.Vine; + mappings[973] = ItemType.WanderingTraderSpawnEgg; + mappings[974] = ItemType.WardenSpawnEgg; + mappings[642] = ItemType.WarpedButton; + mappings[665] = ItemType.WarpedDoor; + mappings[276] = ItemType.WarpedFence; + mappings[684] = ItemType.WarpedFenceGate; + mappings[200] = ItemType.WarpedFungus; + mappings[696] = ItemType.WarpedFungusOnAStick; + mappings[141] = ItemType.WarpedHyphae; + mappings[21] = ItemType.WarpedNylium; + mappings[31] = ItemType.WarpedPlanks; + mappings[655] = ItemType.WarpedPressurePlate; + mappings[202] = ItemType.WarpedRoots; + mappings[812] = ItemType.WarpedSign; + mappings[222] = ItemType.WarpedSlab; + mappings[346] = ItemType.WarpedStairs; + mappings[114] = ItemType.WarpedStem; + mappings[675] = ItemType.WarpedTrapdoor; + mappings[470] = ItemType.WarpedWartBlock; + mappings[814] = ItemType.WaterBucket; + mappings[88] = ItemType.WaxedCopperBlock; + mappings[92] = ItemType.WaxedCutCopper; + mappings[100] = ItemType.WaxedCutCopperSlab; + mappings[96] = ItemType.WaxedCutCopperStairs; + mappings[89] = ItemType.WaxedExposedCopper; + mappings[93] = ItemType.WaxedExposedCutCopper; + mappings[101] = ItemType.WaxedExposedCutCopperSlab; + mappings[97] = ItemType.WaxedExposedCutCopperStairs; + mappings[91] = ItemType.WaxedOxidizedCopper; + mappings[95] = ItemType.WaxedOxidizedCutCopper; + mappings[103] = ItemType.WaxedOxidizedCutCopperSlab; + mappings[99] = ItemType.WaxedOxidizedCutCopperStairs; + mappings[90] = ItemType.WaxedWeatheredCopper; + mappings[94] = ItemType.WaxedWeatheredCutCopper; + mappings[102] = ItemType.WaxedWeatheredCutCopperSlab; + mappings[98] = ItemType.WaxedWeatheredCutCopperStairs; + mappings[74] = ItemType.WeatheredCopper; + mappings[78] = ItemType.WeatheredCutCopper; + mappings[86] = ItemType.WeatheredCutCopperSlab; + mappings[82] = ItemType.WeatheredCutCopperStairs; + mappings[204] = ItemType.WeepingVines; + mappings[152] = ItemType.WetSponge; + mappings[772] = ItemType.Wheat; + mappings[771] = ItemType.WheatSeeds; + mappings[1025] = ItemType.WhiteBanner; + mappings[869] = ItemType.WhiteBed; + mappings[1126] = ItemType.WhiteCandle; + mappings[398] = ItemType.WhiteCarpet; + mappings[507] = ItemType.WhiteConcrete; + mappings[523] = ItemType.WhiteConcretePowder; + mappings[849] = ItemType.WhiteDye; + mappings[491] = ItemType.WhiteGlazedTerracotta; + mappings[475] = ItemType.WhiteShulkerBox; + mappings[423] = ItemType.WhiteStainedGlass; + mappings[439] = ItemType.WhiteStainedGlassPane; + mappings[379] = ItemType.WhiteTerracotta; + mappings[190] = ItemType.WhiteTulip; + mappings[167] = ItemType.WhiteWool; + mappings[975] = ItemType.WitchSpawnEgg; + mappings[195] = ItemType.WitherRose; + mappings[997] = ItemType.WitherSkeletonSkull; + mappings[976] = ItemType.WitherSkeletonSpawnEgg; + mappings[977] = ItemType.WolfSpawnEgg; + mappings[738] = ItemType.WoodenAxe; + mappings[739] = ItemType.WoodenHoe; + mappings[737] = ItemType.WoodenPickaxe; + mappings[736] = ItemType.WoodenShovel; + mappings[735] = ItemType.WoodenSword; + mappings[985] = ItemType.WritableBook; + mappings[986] = ItemType.WrittenBook; + mappings[1029] = ItemType.YellowBanner; + mappings[873] = ItemType.YellowBed; + mappings[1130] = ItemType.YellowCandle; + mappings[402] = ItemType.YellowCarpet; + mappings[511] = ItemType.YellowConcrete; + mappings[527] = ItemType.YellowConcretePowder; + mappings[853] = ItemType.YellowDye; + mappings[495] = ItemType.YellowGlazedTerracotta; + mappings[479] = ItemType.YellowShulkerBox; + mappings[427] = ItemType.YellowStainedGlass; + mappings[443] = ItemType.YellowStainedGlassPane; + mappings[383] = ItemType.YellowTerracotta; + mappings[171] = ItemType.YellowWool; + mappings[978] = ItemType.ZoglinSpawnEgg; + mappings[999] = ItemType.ZombieHead; + mappings[980] = ItemType.ZombieHorseSpawnEgg; + mappings[979] = ItemType.ZombieSpawnEgg; + mappings[981] = ItemType.ZombieVillagerSpawnEgg; + mappings[982] = ItemType.ZombifiedPiglinSpawnEgg; + } + + protected override Dictionary GetDict() + { + return mappings; + } + } +} diff --git a/MinecraftClient/Inventory/ItemType.cs b/MinecraftClient/Inventory/ItemType.cs index 062e93e3..50966bf0 100644 --- a/MinecraftClient/Inventory/ItemType.cs +++ b/MinecraftClient/Inventory/ItemType.cs @@ -1,11 +1,10 @@ namespace MinecraftClient.Inventory { /// - /// For MC version 1.16.2. - /// Generated using ItemPaletteGenerator. + /// Generated using the --generator flag on the client /// Typical steps to handle new item IDs for newer Minecraft versions: - /// 1. Generate registries.json using data reporting on Vanilla Minecraft (https://wiki.vg/Data_Generators) - /// 2. Generate temporary ItemTypeXXX.cs and ItemPaletteXXX.cs using ItemPaletteGenerator.cs + /// 1. Generate registries.json using data reporting on Vanilla Minecraft (https://wiki.vg/Data_Generators) or download it from: https://github.com/PixiGeko/Minecraft-generated-data + /// 2. Generate temporary ItemTypeXXX.cs and ItemPaletteXXX.cs using the --generator flag on the client /// 3. Perform a diff with existing versions, add missing entries in ItemType.cs and ItemTypeExtensions.cs /// 4. If existing entity IDs were not randomized by Mojang, simply add missing entries to the latest existing ItemPaletteXXX.cs /// 5. If existing entity IDs were randomized, add a new palette as ItemPaletteXXX.cs into the codebase @@ -14,9 +13,10 @@ namespace MinecraftClient.Inventory { Unknown = -2, // Unsupported item type (Forge mod custom item...) Null = -1, // Unspecified item type (Used in the network protocol) - + AcaciaBoat, AcaciaButton, + AcaciaChestBoat, AcaciaDoor, AcaciaFence, AcaciaFenceGate, @@ -32,6 +32,7 @@ namespace MinecraftClient.Inventory AcaciaWood, ActivatorRail, Air, + AllaySpawnEgg, Allium, AmethystBlock, AmethystCluster, @@ -69,6 +70,7 @@ namespace MinecraftClient.Inventory BigDripleaf, BirchBoat, BirchButton, + BirchChestBoat, BirchDoor, BirchFence, BirchFenceGate, @@ -279,6 +281,7 @@ namespace MinecraftClient.Inventory Dandelion, DarkOakBoat, DarkOakButton, + DarkOakChestBoat, DarkOakDoor, DarkOakFence, DarkOakFenceGate, @@ -349,6 +352,8 @@ namespace MinecraftClient.Inventory DioriteStairs, DioriteWall, Dirt, + DirtPath, + DiscFragment5, Dispenser, DolphinSpawnEgg, DonkeySpawnEgg, @@ -360,6 +365,7 @@ namespace MinecraftClient.Inventory DripstoneBlock, Dropper, DrownedSpawnEgg, + EchoShard, Egg, ElderGuardianSpawnEgg, Elytra, @@ -408,6 +414,8 @@ namespace MinecraftClient.Inventory FloweringAzalea, FloweringAzaleaLeaves, FoxSpawnEgg, + FrogSpawnEgg, + Frogspawn, Furnace, FurnaceMinecart, GhastSpawnEgg, @@ -425,6 +433,7 @@ namespace MinecraftClient.Inventory GlowSquidSpawnEgg, Glowstone, GlowstoneDust, + GoatHorn, GoatSpawnEgg, GoldBlock, GoldIngot, @@ -448,7 +457,6 @@ namespace MinecraftClient.Inventory GraniteWall, Grass, GrassBlock, - GrassPath, Gravel, GrayBanner, GrayBed, @@ -527,6 +535,7 @@ namespace MinecraftClient.Inventory Jukebox, JungleBoat, JungleButton, + JungleChestBoat, JungleDoor, JungleFence, JungleFenceGate, @@ -624,6 +633,23 @@ namespace MinecraftClient.Inventory MagmaBlock, MagmaCream, MagmaCubeSpawnEgg, + MangroveBoat, + MangroveButton, + MangroveChestBoat, + MangroveDoor, + MangroveFence, + MangroveFenceGate, + MangroveLeaves, + MangroveLog, + MangrovePlanks, + MangrovePressurePlate, + MangrovePropagule, + MangroveRoots, + MangroveSign, + MangroveSlab, + MangroveStairs, + MangroveTrapdoor, + MangroveWood, Map, MediumAmethystBud, Melon, @@ -643,11 +669,18 @@ namespace MinecraftClient.Inventory MossyStoneBrickStairs, MossyStoneBrickWall, MossyStoneBricks, + Mud, + MudBrickSlab, + MudBrickStairs, + MudBrickWall, + MudBricks, + MuddyMangroveRoots, MuleSpawnEgg, MushroomStem, MushroomStew, MusicDisc11, MusicDisc13, + MusicDisc5, MusicDiscBlocks, MusicDiscCat, MusicDiscChirp, @@ -692,6 +725,7 @@ namespace MinecraftClient.Inventory NoteBlock, OakBoat, OakButton, + OakChestBoat, OakDoor, OakFence, OakFenceGate, @@ -708,6 +742,7 @@ namespace MinecraftClient.Inventory Observer, Obsidian, OcelotSpawnEgg, + OchreFroglight, OrangeBanner, OrangeBed, OrangeCandle, @@ -728,10 +763,12 @@ namespace MinecraftClient.Inventory OxidizedCutCopperSlab, OxidizedCutCopperStairs, PackedIce, + PackedMud, Painting, PandaSpawnEgg, Paper, ParrotSpawnEgg, + PearlescentFroglight, Peony, PetrifiedOakSlab, PhantomMembrane, @@ -843,6 +880,7 @@ namespace MinecraftClient.Inventory RawGoldBlock, RawIron, RawIronBlock, + RecoveryCompass, RedBanner, RedBed, RedCandle, @@ -873,6 +911,7 @@ namespace MinecraftClient.Inventory RedstoneLamp, RedstoneOre, RedstoneTorch, + ReinforcedDeepslate, Repeater, RepeatingCommandBlock, RespawnAnchor, @@ -889,7 +928,11 @@ namespace MinecraftClient.Inventory SandstoneStairs, SandstoneWall, Scaffolding, + Sculk, + SculkCatalyst, SculkSensor, + SculkShrieker, + SculkVein, Scute, SeaLantern, SeaPickle, @@ -942,6 +985,7 @@ namespace MinecraftClient.Inventory SporeBlossom, SpruceBoat, SpruceButton, + SpruceChestBoat, SpruceDoor, SpruceFence, SpruceFenceGate, @@ -987,6 +1031,8 @@ namespace MinecraftClient.Inventory StrippedDarkOakWood, StrippedJungleLog, StrippedJungleWood, + StrippedMangroveLog, + StrippedMangroveWood, StrippedOakLog, StrippedOakWood, StrippedSpruceLog, @@ -1000,6 +1046,8 @@ namespace MinecraftClient.Inventory Sunflower, SuspiciousStew, SweetBerries, + TadpoleBucket, + TadpoleSpawnEgg, TallGrass, Target, Terracotta, @@ -1024,11 +1072,13 @@ namespace MinecraftClient.Inventory TurtleHelmet, TurtleSpawnEgg, TwistingVines, + VerdantFroglight, VexSpawnEgg, VillagerSpawnEgg, VindicatorSpawnEgg, Vine, WanderingTraderSpawnEgg, + WardenSpawnEgg, WarpedButton, WarpedDoor, WarpedFence, diff --git a/MinecraftClient/Mapping/BlockPalettes/Palette113.cs b/MinecraftClient/Mapping/BlockPalettes/Palette113.cs index ca29cfab..b0e2006d 100644 --- a/MinecraftClient/Mapping/BlockPalettes/Palette113.cs +++ b/MinecraftClient/Mapping/BlockPalettes/Palette113.cs @@ -760,7 +760,7 @@ namespace MinecraftClient.Mapping.BlockPalettes materials[8158] = Material.EndStoneBricks; for (int i = 8159; i <= 8162; i++) materials[i] = Material.Beetroots; - materials[8163] = Material.GrassPath; + materials[8163] = Material.DirtPath; materials[8164] = Material.EndGateway; for (int i = 8165; i <= 8176; i++) materials[i] = Material.RepeatingCommandBlock; diff --git a/MinecraftClient/Mapping/BlockPalettes/Palette114.cs b/MinecraftClient/Mapping/BlockPalettes/Palette114.cs index 2503f1bb..b44b20d6 100644 --- a/MinecraftClient/Mapping/BlockPalettes/Palette114.cs +++ b/MinecraftClient/Mapping/BlockPalettes/Palette114.cs @@ -792,7 +792,7 @@ namespace MinecraftClient.Mapping.BlockPalettes materials[8682] = Material.EndStoneBricks; for (int i = 8683; i <= 8686; i++) materials[i] = Material.Beetroots; - materials[8687] = Material.GrassPath; + materials[8687] = Material.DirtPath; materials[8688] = Material.EndGateway; for (int i = 8689; i <= 8700; i++) materials[i] = Material.RepeatingCommandBlock; diff --git a/MinecraftClient/Mapping/BlockPalettes/Palette115.cs b/MinecraftClient/Mapping/BlockPalettes/Palette115.cs index b56accc1..e84fbd11 100644 --- a/MinecraftClient/Mapping/BlockPalettes/Palette115.cs +++ b/MinecraftClient/Mapping/BlockPalettes/Palette115.cs @@ -792,7 +792,7 @@ namespace MinecraftClient.Mapping.BlockPalettes materials[8682] = Material.EndStoneBricks; for (int i = 8683; i <= 8686; i++) materials[i] = Material.Beetroots; - materials[8687] = Material.GrassPath; + materials[8687] = Material.DirtPath; materials[8688] = Material.EndGateway; for (int i = 8689; i <= 8700; i++) materials[i] = Material.RepeatingCommandBlock; diff --git a/MinecraftClient/Mapping/BlockPalettes/Palette116.cs b/MinecraftClient/Mapping/BlockPalettes/Palette116.cs index e44085f8..1d63b6b4 100644 --- a/MinecraftClient/Mapping/BlockPalettes/Palette116.cs +++ b/MinecraftClient/Mapping/BlockPalettes/Palette116.cs @@ -800,7 +800,7 @@ namespace MinecraftClient.Mapping.BlockPalettes materials[9222] = Material.EndStoneBricks; for (int i = 9223; i <= 9226; i++) materials[i] = Material.Beetroots; - materials[9227] = Material.GrassPath; + materials[9227] = Material.DirtPath; materials[9228] = Material.EndGateway; for (int i = 9229; i <= 9240; i++) materials[i] = Material.RepeatingCommandBlock; diff --git a/MinecraftClient/Mapping/BlockPalettes/Palette117.cs b/MinecraftClient/Mapping/BlockPalettes/Palette117.cs index 6a8f78c6..826b630e 100644 --- a/MinecraftClient/Mapping/BlockPalettes/Palette117.cs +++ b/MinecraftClient/Mapping/BlockPalettes/Palette117.cs @@ -820,7 +820,7 @@ namespace MinecraftClient.Mapping.BlockPalettes materials[9468] = Material.EndStoneBricks; for (int i = 9469; i <= 9472; i++) materials[i] = Material.Beetroots; - materials[9473] = Material.GrassPath; + materials[9473] = Material.DirtPath; materials[9474] = Material.EndGateway; for (int i = 9475; i <= 9486; i++) materials[i] = Material.RepeatingCommandBlock; diff --git a/MinecraftClient/Mapping/BlockPalettes/Palette119.cs b/MinecraftClient/Mapping/BlockPalettes/Palette119.cs new file mode 100644 index 00000000..88521065 --- /dev/null +++ b/MinecraftClient/Mapping/BlockPalettes/Palette119.cs @@ -0,0 +1,1530 @@ +using System; +using System.Collections.Generic; + +namespace MinecraftClient.Mapping.BlockPalettes +{ + public class Palette119 : BlockPalette + { + private static Dictionary materials = new Dictionary(); + + static Palette119() + { + for (int i = 7035; i <= 7058; i++) + materials[i] = Material.AcaciaButton; + for (int i = 9747; i <= 9810; i++) + materials[i] = Material.AcaciaDoor; + for (int i = 9459; i <= 9490; i++) + materials[i] = Material.AcaciaFence; + for (int i = 9267; i <= 9298; i++) + materials[i] = Material.AcaciaFenceGate; + for (int i = 318; i <= 345; i++) + materials[i] = Material.AcaciaLeaves; + for (int i = 129; i <= 131; i++) + materials[i] = Material.AcaciaLog; + materials[19] = Material.AcaciaPlanks; + for (int i = 4186; i <= 4187; i++) + materials[i] = Material.AcaciaPressurePlate; + for (int i = 30; i <= 31; i++) + materials[i] = Material.AcaciaSapling; + for (int i = 3732; i <= 3763; i++) + materials[i] = Material.AcaciaSign; + for (int i = 9065; i <= 9070; i++) + materials[i] = Material.AcaciaSlab; + for (int i = 8004; i <= 8083; i++) + materials[i] = Material.AcaciaStairs; + for (int i = 4676; i <= 4739; i++) + materials[i] = Material.AcaciaTrapdoor; + for (int i = 4056; i <= 4063; i++) + materials[i] = Material.AcaciaWallSign; + for (int i = 176; i <= 178; i++) + materials[i] = Material.AcaciaWood; + for (int i = 7440; i <= 7463; i++) + materials[i] = Material.ActivatorRail; + materials[0] = Material.Air; + materials[1669] = Material.Allium; + materials[18619] = Material.AmethystBlock; + for (int i = 18621; i <= 18632; i++) + materials[i] = Material.AmethystCluster; + materials[17036] = Material.AncientDebris; + materials[6] = Material.Andesite; + for (int i = 11724; i <= 11729; i++) + materials[i] = Material.AndesiteSlab; + for (int i = 11350; i <= 11429; i++) + materials[i] = Material.AndesiteStairs; + for (int i = 14340; i <= 14663; i++) + materials[i] = Material.AndesiteWall; + for (int i = 7227; i <= 7230; i++) + materials[i] = Material.Anvil; + for (int i = 5147; i <= 5150; i++) + materials[i] = Material.AttachedMelonStem; + for (int i = 5143; i <= 5146; i++) + materials[i] = Material.AttachedPumpkinStem; + materials[19714] = Material.Azalea; + for (int i = 402; i <= 429; i++) + materials[i] = Material.AzaleaLeaves; + materials[1670] = Material.AzureBluet; + for (int i = 10533; i <= 10544; i++) + materials[i] = Material.Bamboo; + materials[10532] = Material.BambooSapling; + for (int i = 15996; i <= 16007; i++) + materials[i] = Material.Barrel; + materials[8245] = Material.Barrier; + for (int i = 4311; i <= 4313; i++) + materials[i] = Material.Basalt; + materials[6248] = Material.Beacon; + materials[74] = Material.Bedrock; + for (int i = 16985; i <= 17008; i++) + materials[i] = Material.BeeNest; + for (int i = 17009; i <= 17032; i++) + materials[i] = Material.Beehive; + for (int i = 10100; i <= 10103; i++) + materials[i] = Material.Beetroots; + for (int i = 16059; i <= 16090; i++) + materials[i] = Material.Bell; + for (int i = 19718; i <= 19749; i++) + materials[i] = Material.BigDripleaf; + for (int i = 19750; i <= 19757; i++) + materials[i] = Material.BigDripleafStem; + for (int i = 6987; i <= 7010; i++) + materials[i] = Material.BirchButton; + for (int i = 9619; i <= 9682; i++) + materials[i] = Material.BirchDoor; + for (int i = 9395; i <= 9426; i++) + materials[i] = Material.BirchFence; + for (int i = 9203; i <= 9234; i++) + materials[i] = Material.BirchFenceGate; + for (int i = 262; i <= 289; i++) + materials[i] = Material.BirchLeaves; + for (int i = 123; i <= 125; i++) + materials[i] = Material.BirchLog; + materials[17] = Material.BirchPlanks; + for (int i = 4182; i <= 4183; i++) + materials[i] = Material.BirchPressurePlate; + for (int i = 26; i <= 27; i++) + materials[i] = Material.BirchSapling; + for (int i = 3700; i <= 3731; i++) + materials[i] = Material.BirchSign; + for (int i = 9053; i <= 9058; i++) + materials[i] = Material.BirchSlab; + for (int i = 6076; i <= 6155; i++) + materials[i] = Material.BirchStairs; + for (int i = 4548; i <= 4611; i++) + materials[i] = Material.BirchTrapdoor; + for (int i = 4048; i <= 4055; i++) + materials[i] = Material.BirchWallSign; + for (int i = 170; i <= 172; i++) + materials[i] = Material.BirchWood; + for (int i = 8878; i <= 8893; i++) + materials[i] = Material.BlackBanner; + for (int i = 1519; i <= 1534; i++) + materials[i] = Material.BlackBed; + for (int i = 18569; i <= 18584; i++) + materials[i] = Material.BlackCandle; + for (int i = 18617; i <= 18618; i++) + materials[i] = Material.BlackCandleCake; + materials[8622] = Material.BlackCarpet; + materials[10334] = Material.BlackConcrete; + materials[10350] = Material.BlackConcretePowder; + for (int i = 10315; i <= 10318; i++) + materials[i] = Material.BlackGlazedTerracotta; + for (int i = 10249; i <= 10254; i++) + materials[i] = Material.BlackShulkerBox; + materials[4419] = Material.BlackStainedGlass; + for (int i = 7972; i <= 8003; i++) + materials[i] = Material.BlackStainedGlassPane; + materials[7491] = Material.BlackTerracotta; + for (int i = 8954; i <= 8957; i++) + materials[i] = Material.BlackWallBanner; + materials[1653] = Material.BlackWool; + materials[17048] = Material.Blackstone; + for (int i = 17453; i <= 17458; i++) + materials[i] = Material.BlackstoneSlab; + for (int i = 17049; i <= 17128; i++) + materials[i] = Material.BlackstoneStairs; + for (int i = 17129; i <= 17452; i++) + materials[i] = Material.BlackstoneWall; + for (int i = 16016; i <= 16023; i++) + materials[i] = Material.BlastFurnace; + for (int i = 8814; i <= 8829; i++) + materials[i] = Material.BlueBanner; + for (int i = 1455; i <= 1470; i++) + materials[i] = Material.BlueBed; + for (int i = 18505; i <= 18520; i++) + materials[i] = Material.BlueCandle; + for (int i = 18609; i <= 18610; i++) + materials[i] = Material.BlueCandleCake; + materials[8618] = Material.BlueCarpet; + materials[10330] = Material.BlueConcrete; + materials[10346] = Material.BlueConcretePowder; + for (int i = 10299; i <= 10302; i++) + materials[i] = Material.BlueGlazedTerracotta; + materials[10529] = Material.BlueIce; + materials[1668] = Material.BlueOrchid; + for (int i = 10225; i <= 10230; i++) + materials[i] = Material.BlueShulkerBox; + materials[4415] = Material.BlueStainedGlass; + for (int i = 7844; i <= 7875; i++) + materials[i] = Material.BlueStainedGlassPane; + materials[7487] = Material.BlueTerracotta; + for (int i = 8938; i <= 8941; i++) + materials[i] = Material.BlueWallBanner; + materials[1649] = Material.BlueWool; + for (int i = 10137; i <= 10139; i++) + materials[i] = Material.BoneBlock; + materials[1686] = Material.Bookshelf; + for (int i = 10413; i <= 10414; i++) + materials[i] = Material.BrainCoral; + materials[10397] = Material.BrainCoralBlock; + for (int i = 10433; i <= 10434; i++) + materials[i] = Material.BrainCoralFan; + for (int i = 10489; i <= 10496; i++) + materials[i] = Material.BrainCoralWallFan; + for (int i = 5720; i <= 5727; i++) + materials[i] = Material.BrewingStand; + for (int i = 9119; i <= 9124; i++) + materials[i] = Material.BrickSlab; + for (int i = 5359; i <= 5438; i++) + materials[i] = Material.BrickStairs; + for (int i = 11748; i <= 12071; i++) + materials[i] = Material.BrickWall; + materials[1683] = Material.Bricks; + for (int i = 8830; i <= 8845; i++) + materials[i] = Material.BrownBanner; + for (int i = 1471; i <= 1486; i++) + materials[i] = Material.BrownBed; + for (int i = 18521; i <= 18536; i++) + materials[i] = Material.BrownCandle; + for (int i = 18611; i <= 18612; i++) + materials[i] = Material.BrownCandleCake; + materials[8619] = Material.BrownCarpet; + materials[10331] = Material.BrownConcrete; + materials[10347] = Material.BrownConcretePowder; + for (int i = 10303; i <= 10306; i++) + materials[i] = Material.BrownGlazedTerracotta; + materials[1679] = Material.BrownMushroom; + for (int i = 4880; i <= 4943; i++) + materials[i] = Material.BrownMushroomBlock; + for (int i = 10231; i <= 10236; i++) + materials[i] = Material.BrownShulkerBox; + materials[4416] = Material.BrownStainedGlass; + for (int i = 7876; i <= 7907; i++) + materials[i] = Material.BrownStainedGlassPane; + materials[7488] = Material.BrownTerracotta; + for (int i = 8942; i <= 8945; i++) + materials[i] = Material.BrownWallBanner; + materials[1650] = Material.BrownWool; + for (int i = 10548; i <= 10549; i++) + materials[i] = Material.BubbleColumn; + for (int i = 10415; i <= 10416; i++) + materials[i] = Material.BubbleCoral; + materials[10398] = Material.BubbleCoralBlock; + for (int i = 10435; i <= 10436; i++) + materials[i] = Material.BubbleCoralFan; + for (int i = 10497; i <= 10504; i++) + materials[i] = Material.BubbleCoralWallFan; + materials[18620] = Material.BuddingAmethyst; + for (int i = 4240; i <= 4255; i++) + materials[i] = Material.Cactus; + for (int i = 4333; i <= 4339; i++) + materials[i] = Material.Cake; + materials[18670] = Material.Calcite; + for (int i = 16099; i <= 16130; i++) + materials[i] = Material.Campfire; + for (int i = 18313; i <= 18328; i++) + materials[i] = Material.Candle; + for (int i = 18585; i <= 18586; i++) + materials[i] = Material.CandleCake; + for (int i = 6923; i <= 6930; i++) + materials[i] = Material.Carrots; + materials[16024] = Material.CartographyTable; + for (int i = 4325; i <= 4328; i++) + materials[i] = Material.CarvedPumpkin; + materials[5728] = Material.Cauldron; + materials[10547] = Material.CaveAir; + for (int i = 19659; i <= 19710; i++) + materials[i] = Material.CaveVines; + for (int i = 19711; i <= 19712; i++) + materials[i] = Material.CaveVinesPlant; + for (int i = 5104; i <= 5109; i++) + materials[i] = Material.Chain; + for (int i = 10118; i <= 10129; i++) + materials[i] = Material.ChainCommandBlock; + for (int i = 2288; i <= 2311; i++) + materials[i] = Material.Chest; + for (int i = 7231; i <= 7234; i++) + materials[i] = Material.ChippedAnvil; + materials[21425] = Material.ChiseledDeepslate; + materials[18310] = Material.ChiseledNetherBricks; + materials[17462] = Material.ChiseledPolishedBlackstone; + materials[7356] = Material.ChiseledQuartzBlock; + materials[8959] = Material.ChiseledRedSandstone; + materials[477] = Material.ChiseledSandstone; + materials[4871] = Material.ChiseledStoneBricks; + for (int i = 10009; i <= 10014; i++) + materials[i] = Material.ChorusFlower; + for (int i = 9945; i <= 10008; i++) + materials[i] = Material.ChorusPlant; + materials[4256] = Material.Clay; + materials[8624] = Material.CoalBlock; + materials[114] = Material.CoalOre; + materials[11] = Material.CoarseDirt; + materials[19781] = Material.CobbledDeepslate; + for (int i = 19862; i <= 19867; i++) + materials[i] = Material.CobbledDeepslateSlab; + for (int i = 19782; i <= 19861; i++) + materials[i] = Material.CobbledDeepslateStairs; + for (int i = 19868; i <= 20191; i++) + materials[i] = Material.CobbledDeepslateWall; + materials[14] = Material.Cobblestone; + for (int i = 9113; i <= 9118; i++) + materials[i] = Material.CobblestoneSlab; + for (int i = 3952; i <= 4031; i++) + materials[i] = Material.CobblestoneStairs; + for (int i = 6249; i <= 6572; i++) + materials[i] = Material.CobblestoneWall; + materials[1595] = Material.Cobweb; + for (int i = 5749; i <= 5760; i++) + materials[i] = Material.Cocoa; + for (int i = 6236; i <= 6247; i++) + materials[i] = Material.CommandBlock; + for (int i = 7295; i <= 7310; i++) + materials[i] = Material.Comparator; + for (int i = 16960; i <= 16968; i++) + materials[i] = Material.Composter; + for (int i = 10530; i <= 10531; i++) + materials[i] = Material.Conduit; + materials[18911] = Material.CopperBlock; + materials[18912] = Material.CopperOre; + materials[1676] = Material.Cornflower; + materials[21426] = Material.CrackedDeepslateBricks; + materials[21427] = Material.CrackedDeepslateTiles; + materials[18311] = Material.CrackedNetherBricks; + materials[17461] = Material.CrackedPolishedBlackstoneBricks; + materials[4870] = Material.CrackedStoneBricks; + materials[3611] = Material.CraftingTable; + for (int i = 7187; i <= 7202; i++) + materials[i] = Material.CreeperHead; + for (int i = 7203; i <= 7206; i++) + materials[i] = Material.CreeperWallHead; + for (int i = 16688; i <= 16711; i++) + materials[i] = Material.CrimsonButton; + for (int i = 16736; i <= 16799; i++) + materials[i] = Material.CrimsonDoor; + for (int i = 16272; i <= 16303; i++) + materials[i] = Material.CrimsonFence; + for (int i = 16464; i <= 16495; i++) + materials[i] = Material.CrimsonFenceGate; + materials[16197] = Material.CrimsonFungus; + for (int i = 16190; i <= 16192; i++) + materials[i] = Material.CrimsonHyphae; + materials[16196] = Material.CrimsonNylium; + materials[16254] = Material.CrimsonPlanks; + for (int i = 16268; i <= 16269; i++) + materials[i] = Material.CrimsonPressurePlate; + materials[16253] = Material.CrimsonRoots; + for (int i = 16864; i <= 16895; i++) + materials[i] = Material.CrimsonSign; + for (int i = 16256; i <= 16261; i++) + materials[i] = Material.CrimsonSlab; + for (int i = 16528; i <= 16607; i++) + materials[i] = Material.CrimsonStairs; + for (int i = 16184; i <= 16186; i++) + materials[i] = Material.CrimsonStem; + for (int i = 16336; i <= 16399; i++) + materials[i] = Material.CrimsonTrapdoor; + for (int i = 16928; i <= 16935; i++) + materials[i] = Material.CrimsonWallSign; + materials[17037] = Material.CryingObsidian; + materials[18917] = Material.CutCopper; + for (int i = 19256; i <= 19261; i++) + materials[i] = Material.CutCopperSlab; + for (int i = 19158; i <= 19237; i++) + materials[i] = Material.CutCopperStairs; + materials[8960] = Material.CutRedSandstone; + for (int i = 9155; i <= 9160; i++) + materials[i] = Material.CutRedSandstoneSlab; + materials[478] = Material.CutSandstone; + for (int i = 9101; i <= 9106; i++) + materials[i] = Material.CutSandstoneSlab; + for (int i = 8782; i <= 8797; i++) + materials[i] = Material.CyanBanner; + for (int i = 1423; i <= 1438; i++) + materials[i] = Material.CyanBed; + for (int i = 18473; i <= 18488; i++) + materials[i] = Material.CyanCandle; + for (int i = 18605; i <= 18606; i++) + materials[i] = Material.CyanCandleCake; + materials[8616] = Material.CyanCarpet; + materials[10328] = Material.CyanConcrete; + materials[10344] = Material.CyanConcretePowder; + for (int i = 10291; i <= 10294; i++) + materials[i] = Material.CyanGlazedTerracotta; + for (int i = 10213; i <= 10218; i++) + materials[i] = Material.CyanShulkerBox; + materials[4413] = Material.CyanStainedGlass; + for (int i = 7780; i <= 7811; i++) + materials[i] = Material.CyanStainedGlassPane; + materials[7485] = Material.CyanTerracotta; + for (int i = 8930; i <= 8933; i++) + materials[i] = Material.CyanWallBanner; + materials[1647] = Material.CyanWool; + for (int i = 7235; i <= 7238; i++) + materials[i] = Material.DamagedAnvil; + materials[1666] = Material.Dandelion; + for (int i = 7059; i <= 7082; i++) + materials[i] = Material.DarkOakButton; + for (int i = 9811; i <= 9874; i++) + materials[i] = Material.DarkOakDoor; + for (int i = 9491; i <= 9522; i++) + materials[i] = Material.DarkOakFence; + for (int i = 9299; i <= 9330; i++) + materials[i] = Material.DarkOakFenceGate; + for (int i = 346; i <= 373; i++) + materials[i] = Material.DarkOakLeaves; + for (int i = 132; i <= 134; i++) + materials[i] = Material.DarkOakLog; + materials[20] = Material.DarkOakPlanks; + for (int i = 4188; i <= 4189; i++) + materials[i] = Material.DarkOakPressurePlate; + for (int i = 32; i <= 33; i++) + materials[i] = Material.DarkOakSapling; + for (int i = 3796; i <= 3827; i++) + materials[i] = Material.DarkOakSign; + for (int i = 9071; i <= 9076; i++) + materials[i] = Material.DarkOakSlab; + for (int i = 8084; i <= 8163; i++) + materials[i] = Material.DarkOakStairs; + for (int i = 4740; i <= 4803; i++) + materials[i] = Material.DarkOakTrapdoor; + for (int i = 4072; i <= 4079; i++) + materials[i] = Material.DarkOakWallSign; + for (int i = 179; i <= 181; i++) + materials[i] = Material.DarkOakWood; + materials[8344] = Material.DarkPrismarine; + for (int i = 8597; i <= 8602; i++) + materials[i] = Material.DarkPrismarineSlab; + for (int i = 8505; i <= 8584; i++) + materials[i] = Material.DarkPrismarineStairs; + for (int i = 7311; i <= 7342; i++) + materials[i] = Material.DaylightDetector; + for (int i = 10403; i <= 10404; i++) + materials[i] = Material.DeadBrainCoral; + materials[10392] = Material.DeadBrainCoralBlock; + for (int i = 10423; i <= 10424; i++) + materials[i] = Material.DeadBrainCoralFan; + for (int i = 10449; i <= 10456; i++) + materials[i] = Material.DeadBrainCoralWallFan; + for (int i = 10405; i <= 10406; i++) + materials[i] = Material.DeadBubbleCoral; + materials[10393] = Material.DeadBubbleCoralBlock; + for (int i = 10425; i <= 10426; i++) + materials[i] = Material.DeadBubbleCoralFan; + for (int i = 10457; i <= 10464; i++) + materials[i] = Material.DeadBubbleCoralWallFan; + materials[1598] = Material.DeadBush; + for (int i = 10407; i <= 10408; i++) + materials[i] = Material.DeadFireCoral; + materials[10394] = Material.DeadFireCoralBlock; + for (int i = 10427; i <= 10428; i++) + materials[i] = Material.DeadFireCoralFan; + for (int i = 10465; i <= 10472; i++) + materials[i] = Material.DeadFireCoralWallFan; + for (int i = 10409; i <= 10410; i++) + materials[i] = Material.DeadHornCoral; + materials[10395] = Material.DeadHornCoralBlock; + for (int i = 10429; i <= 10430; i++) + materials[i] = Material.DeadHornCoralFan; + for (int i = 10473; i <= 10480; i++) + materials[i] = Material.DeadHornCoralWallFan; + for (int i = 10401; i <= 10402; i++) + materials[i] = Material.DeadTubeCoral; + materials[10391] = Material.DeadTubeCoralBlock; + for (int i = 10421; i <= 10422; i++) + materials[i] = Material.DeadTubeCoralFan; + for (int i = 10441; i <= 10448; i++) + materials[i] = Material.DeadTubeCoralWallFan; + for (int i = 19778; i <= 19780; i++) + materials[i] = Material.Deepslate; + for (int i = 21095; i <= 21100; i++) + materials[i] = Material.DeepslateBrickSlab; + for (int i = 21015; i <= 21094; i++) + materials[i] = Material.DeepslateBrickStairs; + for (int i = 21101; i <= 21424; i++) + materials[i] = Material.DeepslateBrickWall; + materials[21014] = Material.DeepslateBricks; + materials[115] = Material.DeepslateCoalOre; + materials[18913] = Material.DeepslateCopperOre; + materials[3609] = Material.DeepslateDiamondOre; + materials[5842] = Material.DeepslateEmeraldOre; + materials[111] = Material.DeepslateGoldOre; + materials[113] = Material.DeepslateIronOre; + materials[462] = Material.DeepslateLapisOre; + for (int i = 4194; i <= 4195; i++) + materials[i] = Material.DeepslateRedstoneOre; + for (int i = 20684; i <= 20689; i++) + materials[i] = Material.DeepslateTileSlab; + for (int i = 20604; i <= 20683; i++) + materials[i] = Material.DeepslateTileStairs; + for (int i = 20690; i <= 21013; i++) + materials[i] = Material.DeepslateTileWall; + materials[20603] = Material.DeepslateTiles; + for (int i = 1559; i <= 1582; i++) + materials[i] = Material.DetectorRail; + materials[3610] = Material.DiamondBlock; + materials[3608] = Material.DiamondOre; + materials[4] = Material.Diorite; + for (int i = 11742; i <= 11747; i++) + materials[i] = Material.DioriteSlab; + for (int i = 11590; i <= 11669; i++) + materials[i] = Material.DioriteStairs; + for (int i = 15636; i <= 15959; i++) + materials[i] = Material.DioriteWall; + materials[10] = Material.Dirt; + materials[10104] = Material.DirtPath; + for (int i = 464; i <= 475; i++) + materials[i] = Material.Dispenser; + materials[5746] = Material.DragonEgg; + for (int i = 7207; i <= 7222; i++) + materials[i] = Material.DragonHead; + for (int i = 7223; i <= 7226; i++) + materials[i] = Material.DragonWallHead; + materials[10378] = Material.DriedKelpBlock; + materials[19658] = Material.DripstoneBlock; + for (int i = 7464; i <= 7475; i++) + materials[i] = Material.Dropper; + materials[5995] = Material.EmeraldBlock; + materials[5841] = Material.EmeraldOre; + materials[5719] = Material.EnchantingTable; + materials[10105] = Material.EndGateway; + materials[5736] = Material.EndPortal; + for (int i = 5737; i <= 5744; i++) + materials[i] = Material.EndPortalFrame; + for (int i = 9939; i <= 9944; i++) + materials[i] = Material.EndRod; + materials[5745] = Material.EndStone; + for (int i = 11700; i <= 11705; i++) + materials[i] = Material.EndStoneBrickSlab; + for (int i = 10950; i <= 11029; i++) + materials[i] = Material.EndStoneBrickStairs; + for (int i = 15312; i <= 15635; i++) + materials[i] = Material.EndStoneBrickWall; + materials[10099] = Material.EndStoneBricks; + for (int i = 5843; i <= 5850; i++) + materials[i] = Material.EnderChest; + materials[18910] = Material.ExposedCopper; + materials[18916] = Material.ExposedCutCopper; + for (int i = 19250; i <= 19255; i++) + materials[i] = Material.ExposedCutCopperSlab; + for (int i = 19078; i <= 19157; i++) + materials[i] = Material.ExposedCutCopperStairs; + for (int i = 3620; i <= 3627; i++) + materials[i] = Material.Farmland; + materials[1597] = Material.Fern; + for (int i = 1694; i <= 2205; i++) + materials[i] = Material.Fire; + for (int i = 10417; i <= 10418; i++) + materials[i] = Material.FireCoral; + materials[10399] = Material.FireCoralBlock; + for (int i = 10437; i <= 10438; i++) + materials[i] = Material.FireCoralFan; + for (int i = 10505; i <= 10512; i++) + materials[i] = Material.FireCoralWallFan; + materials[16025] = Material.FletchingTable; + materials[6897] = Material.FlowerPot; + materials[19715] = Material.FloweringAzalea; + for (int i = 430; i <= 457; i++) + materials[i] = Material.FloweringAzaleaLeaves; + materials[21446] = Material.Frogspawn; + for (int i = 10130; i <= 10133; i++) + materials[i] = Material.FrostedIce; + for (int i = 3628; i <= 3635; i++) + materials[i] = Material.Furnace; + materials[17873] = Material.GildedBlackstone; + materials[460] = Material.Glass; + for (int i = 5110; i <= 5141; i++) + materials[i] = Material.GlassPane; + for (int i = 5199; i <= 5326; i++) + materials[i] = Material.GlowLichen; + materials[4322] = Material.Glowstone; + materials[1681] = Material.GoldBlock; + materials[110] = Material.GoldOre; + materials[2] = Material.Granite; + for (int i = 11718; i <= 11723; i++) + materials[i] = Material.GraniteSlab; + for (int i = 11270; i <= 11349; i++) + materials[i] = Material.GraniteStairs; + for (int i = 13044; i <= 13367; i++) + materials[i] = Material.GraniteWall; + materials[1596] = Material.Grass; + for (int i = 8; i <= 9; i++) + materials[i] = Material.GrassBlock; + materials[109] = Material.Gravel; + for (int i = 8750; i <= 8765; i++) + materials[i] = Material.GrayBanner; + for (int i = 1391; i <= 1406; i++) + materials[i] = Material.GrayBed; + for (int i = 18441; i <= 18456; i++) + materials[i] = Material.GrayCandle; + for (int i = 18601; i <= 18602; i++) + materials[i] = Material.GrayCandleCake; + materials[8614] = Material.GrayCarpet; + materials[10326] = Material.GrayConcrete; + materials[10342] = Material.GrayConcretePowder; + for (int i = 10283; i <= 10286; i++) + materials[i] = Material.GrayGlazedTerracotta; + for (int i = 10201; i <= 10206; i++) + materials[i] = Material.GrayShulkerBox; + materials[4411] = Material.GrayStainedGlass; + for (int i = 7716; i <= 7747; i++) + materials[i] = Material.GrayStainedGlassPane; + materials[7483] = Material.GrayTerracotta; + for (int i = 8922; i <= 8925; i++) + materials[i] = Material.GrayWallBanner; + materials[1645] = Material.GrayWool; + for (int i = 8846; i <= 8861; i++) + materials[i] = Material.GreenBanner; + for (int i = 1487; i <= 1502; i++) + materials[i] = Material.GreenBed; + for (int i = 18537; i <= 18552; i++) + materials[i] = Material.GreenCandle; + for (int i = 18613; i <= 18614; i++) + materials[i] = Material.GreenCandleCake; + materials[8620] = Material.GreenCarpet; + materials[10332] = Material.GreenConcrete; + materials[10348] = Material.GreenConcretePowder; + for (int i = 10307; i <= 10310; i++) + materials[i] = Material.GreenGlazedTerracotta; + for (int i = 10237; i <= 10242; i++) + materials[i] = Material.GreenShulkerBox; + materials[4417] = Material.GreenStainedGlass; + for (int i = 7908; i <= 7939; i++) + materials[i] = Material.GreenStainedGlassPane; + materials[7489] = Material.GreenTerracotta; + for (int i = 8946; i <= 8949; i++) + materials[i] = Material.GreenWallBanner; + materials[1651] = Material.GreenWool; + for (int i = 16026; i <= 16037; i++) + materials[i] = Material.Grindstone; + for (int i = 19774; i <= 19775; i++) + materials[i] = Material.HangingRoots; + for (int i = 8604; i <= 8606; i++) + materials[i] = Material.HayBlock; + for (int i = 7279; i <= 7294; i++) + materials[i] = Material.HeavyWeightedPressurePlate; + materials[17033] = Material.HoneyBlock; + materials[17034] = Material.HoneycombBlock; + for (int i = 7345; i <= 7354; i++) + materials[i] = Material.Hopper; + for (int i = 10419; i <= 10420; i++) + materials[i] = Material.HornCoral; + materials[10400] = Material.HornCoralBlock; + for (int i = 10439; i <= 10440; i++) + materials[i] = Material.HornCoralFan; + for (int i = 10513; i <= 10520; i++) + materials[i] = Material.HornCoralWallFan; + materials[4238] = Material.Ice; + materials[4879] = Material.InfestedChiseledStoneBricks; + materials[4875] = Material.InfestedCobblestone; + materials[4878] = Material.InfestedCrackedStoneBricks; + for (int i = 21428; i <= 21430; i++) + materials[i] = Material.InfestedDeepslate; + materials[4877] = Material.InfestedMossyStoneBricks; + materials[4874] = Material.InfestedStone; + materials[4876] = Material.InfestedStoneBricks; + for (int i = 5072; i <= 5103; i++) + materials[i] = Material.IronBars; + materials[1682] = Material.IronBlock; + for (int i = 4114; i <= 4177; i++) + materials[i] = Material.IronDoor; + materials[112] = Material.IronOre; + for (int i = 8278; i <= 8341; i++) + materials[i] = Material.IronTrapdoor; + for (int i = 4329; i <= 4332; i++) + materials[i] = Material.JackOLantern; + for (int i = 16948; i <= 16959; i++) + materials[i] = Material.Jigsaw; + for (int i = 4273; i <= 4274; i++) + materials[i] = Material.Jukebox; + for (int i = 7011; i <= 7034; i++) + materials[i] = Material.JungleButton; + for (int i = 9683; i <= 9746; i++) + materials[i] = Material.JungleDoor; + for (int i = 9427; i <= 9458; i++) + materials[i] = Material.JungleFence; + for (int i = 9235; i <= 9266; i++) + materials[i] = Material.JungleFenceGate; + for (int i = 290; i <= 317; i++) + materials[i] = Material.JungleLeaves; + for (int i = 126; i <= 128; i++) + materials[i] = Material.JungleLog; + materials[18] = Material.JunglePlanks; + for (int i = 4184; i <= 4185; i++) + materials[i] = Material.JunglePressurePlate; + for (int i = 28; i <= 29; i++) + materials[i] = Material.JungleSapling; + for (int i = 3764; i <= 3795; i++) + materials[i] = Material.JungleSign; + for (int i = 9059; i <= 9064; i++) + materials[i] = Material.JungleSlab; + for (int i = 6156; i <= 6235; i++) + materials[i] = Material.JungleStairs; + for (int i = 4612; i <= 4675; i++) + materials[i] = Material.JungleTrapdoor; + for (int i = 4064; i <= 4071; i++) + materials[i] = Material.JungleWallSign; + for (int i = 173; i <= 175; i++) + materials[i] = Material.JungleWood; + for (int i = 10351; i <= 10376; i++) + materials[i] = Material.Kelp; + materials[10377] = Material.KelpPlant; + for (int i = 3924; i <= 3931; i++) + materials[i] = Material.Ladder; + for (int i = 16091; i <= 16094; i++) + materials[i] = Material.Lantern; + materials[463] = Material.LapisBlock; + materials[461] = Material.LapisOre; + for (int i = 18633; i <= 18644; i++) + materials[i] = Material.LargeAmethystBud; + for (int i = 8636; i <= 8637; i++) + materials[i] = Material.LargeFern; + for (int i = 91; i <= 106; i++) + materials[i] = Material.Lava; + materials[5732] = Material.LavaCauldron; + for (int i = 16038; i <= 16053; i++) + materials[i] = Material.Lectern; + for (int i = 4088; i <= 4111; i++) + materials[i] = Material.Lever; + for (int i = 8246; i <= 8277; i++) + materials[i] = Material.Light; + for (int i = 8686; i <= 8701; i++) + materials[i] = Material.LightBlueBanner; + for (int i = 1327; i <= 1342; i++) + materials[i] = Material.LightBlueBed; + for (int i = 18377; i <= 18392; i++) + materials[i] = Material.LightBlueCandle; + for (int i = 18593; i <= 18594; i++) + materials[i] = Material.LightBlueCandleCake; + materials[8610] = Material.LightBlueCarpet; + materials[10322] = Material.LightBlueConcrete; + materials[10338] = Material.LightBlueConcretePowder; + for (int i = 10267; i <= 10270; i++) + materials[i] = Material.LightBlueGlazedTerracotta; + for (int i = 10177; i <= 10182; i++) + materials[i] = Material.LightBlueShulkerBox; + materials[4407] = Material.LightBlueStainedGlass; + for (int i = 7588; i <= 7619; i++) + materials[i] = Material.LightBlueStainedGlassPane; + materials[7479] = Material.LightBlueTerracotta; + for (int i = 8906; i <= 8909; i++) + materials[i] = Material.LightBlueWallBanner; + materials[1641] = Material.LightBlueWool; + for (int i = 8766; i <= 8781; i++) + materials[i] = Material.LightGrayBanner; + for (int i = 1407; i <= 1422; i++) + materials[i] = Material.LightGrayBed; + for (int i = 18457; i <= 18472; i++) + materials[i] = Material.LightGrayCandle; + for (int i = 18603; i <= 18604; i++) + materials[i] = Material.LightGrayCandleCake; + materials[8615] = Material.LightGrayCarpet; + materials[10327] = Material.LightGrayConcrete; + materials[10343] = Material.LightGrayConcretePowder; + for (int i = 10287; i <= 10290; i++) + materials[i] = Material.LightGrayGlazedTerracotta; + for (int i = 10207; i <= 10212; i++) + materials[i] = Material.LightGrayShulkerBox; + materials[4412] = Material.LightGrayStainedGlass; + for (int i = 7748; i <= 7779; i++) + materials[i] = Material.LightGrayStainedGlassPane; + materials[7484] = Material.LightGrayTerracotta; + for (int i = 8926; i <= 8929; i++) + materials[i] = Material.LightGrayWallBanner; + materials[1646] = Material.LightGrayWool; + for (int i = 7263; i <= 7278; i++) + materials[i] = Material.LightWeightedPressurePlate; + for (int i = 19614; i <= 19637; i++) + materials[i] = Material.LightningRod; + for (int i = 8628; i <= 8629; i++) + materials[i] = Material.Lilac; + materials[1678] = Material.LilyOfTheValley; + materials[5601] = Material.LilyPad; + for (int i = 8718; i <= 8733; i++) + materials[i] = Material.LimeBanner; + for (int i = 1359; i <= 1374; i++) + materials[i] = Material.LimeBed; + for (int i = 18409; i <= 18424; i++) + materials[i] = Material.LimeCandle; + for (int i = 18597; i <= 18598; i++) + materials[i] = Material.LimeCandleCake; + materials[8612] = Material.LimeCarpet; + materials[10324] = Material.LimeConcrete; + materials[10340] = Material.LimeConcretePowder; + for (int i = 10275; i <= 10278; i++) + materials[i] = Material.LimeGlazedTerracotta; + for (int i = 10189; i <= 10194; i++) + materials[i] = Material.LimeShulkerBox; + materials[4409] = Material.LimeStainedGlass; + for (int i = 7652; i <= 7683; i++) + materials[i] = Material.LimeStainedGlassPane; + materials[7481] = Material.LimeTerracotta; + for (int i = 8914; i <= 8917; i++) + materials[i] = Material.LimeWallBanner; + materials[1643] = Material.LimeWool; + materials[17047] = Material.Lodestone; + for (int i = 15992; i <= 15995; i++) + materials[i] = Material.Loom; + for (int i = 8670; i <= 8685; i++) + materials[i] = Material.MagentaBanner; + for (int i = 1311; i <= 1326; i++) + materials[i] = Material.MagentaBed; + for (int i = 18361; i <= 18376; i++) + materials[i] = Material.MagentaCandle; + for (int i = 18591; i <= 18592; i++) + materials[i] = Material.MagentaCandleCake; + materials[8609] = Material.MagentaCarpet; + materials[10321] = Material.MagentaConcrete; + materials[10337] = Material.MagentaConcretePowder; + for (int i = 10263; i <= 10266; i++) + materials[i] = Material.MagentaGlazedTerracotta; + for (int i = 10171; i <= 10176; i++) + materials[i] = Material.MagentaShulkerBox; + materials[4406] = Material.MagentaStainedGlass; + for (int i = 7556; i <= 7587; i++) + materials[i] = Material.MagentaStainedGlassPane; + materials[7478] = Material.MagentaTerracotta; + for (int i = 8902; i <= 8905; i++) + materials[i] = Material.MagentaWallBanner; + materials[1640] = Material.MagentaWool; + materials[10134] = Material.MagmaBlock; + for (int i = 7083; i <= 7106; i++) + materials[i] = Material.MangroveButton; + for (int i = 9875; i <= 9938; i++) + materials[i] = Material.MangroveDoor; + for (int i = 9523; i <= 9554; i++) + materials[i] = Material.MangroveFence; + for (int i = 9331; i <= 9362; i++) + materials[i] = Material.MangroveFenceGate; + for (int i = 374; i <= 401; i++) + materials[i] = Material.MangroveLeaves; + for (int i = 135; i <= 137; i++) + materials[i] = Material.MangroveLog; + materials[21] = Material.MangrovePlanks; + for (int i = 4190; i <= 4191; i++) + materials[i] = Material.MangrovePressurePlate; + for (int i = 34; i <= 73; i++) + materials[i] = Material.MangrovePropagule; + for (int i = 138; i <= 139; i++) + materials[i] = Material.MangroveRoots; + for (int i = 3828; i <= 3859; i++) + materials[i] = Material.MangroveSign; + for (int i = 9077; i <= 9082; i++) + materials[i] = Material.MangroveSlab; + for (int i = 8164; i <= 8243; i++) + materials[i] = Material.MangroveStairs; + for (int i = 4804; i <= 4867; i++) + materials[i] = Material.MangroveTrapdoor; + for (int i = 4080; i <= 4087; i++) + materials[i] = Material.MangroveWallSign; + for (int i = 182; i <= 184; i++) + materials[i] = Material.MangroveWood; + for (int i = 18645; i <= 18656; i++) + materials[i] = Material.MediumAmethystBud; + materials[5142] = Material.Melon; + for (int i = 5159; i <= 5166; i++) + materials[i] = Material.MelonStem; + materials[19717] = Material.MossBlock; + materials[19716] = Material.MossCarpet; + materials[1687] = Material.MossyCobblestone; + for (int i = 11694; i <= 11699; i++) + materials[i] = Material.MossyCobblestoneSlab; + for (int i = 10870; i <= 10949; i++) + materials[i] = Material.MossyCobblestoneStairs; + for (int i = 6573; i <= 6896; i++) + materials[i] = Material.MossyCobblestoneWall; + for (int i = 11682; i <= 11687; i++) + materials[i] = Material.MossyStoneBrickSlab; + for (int i = 10710; i <= 10789; i++) + materials[i] = Material.MossyStoneBrickStairs; + for (int i = 12720; i <= 13043; i++) + materials[i] = Material.MossyStoneBrickWall; + materials[4869] = Material.MossyStoneBricks; + for (int i = 1654; i <= 1665; i++) + materials[i] = Material.MovingPiston; + materials[19777] = Material.Mud; + for (int i = 9131; i <= 9136; i++) + materials[i] = Material.MudBrickSlab; + for (int i = 5519; i <= 5598; i++) + materials[i] = Material.MudBrickStairs; + for (int i = 13692; i <= 14015; i++) + materials[i] = Material.MudBrickWall; + materials[4873] = Material.MudBricks; + for (int i = 140; i <= 142; i++) + materials[i] = Material.MuddyMangroveRoots; + for (int i = 5008; i <= 5071; i++) + materials[i] = Material.MushroomStem; + for (int i = 5599; i <= 5600; i++) + materials[i] = Material.Mycelium; + for (int i = 5603; i <= 5634; i++) + materials[i] = Material.NetherBrickFence; + for (int i = 9137; i <= 9142; i++) + materials[i] = Material.NetherBrickSlab; + for (int i = 5635; i <= 5714; i++) + materials[i] = Material.NetherBrickStairs; + for (int i = 14016; i <= 14339; i++) + materials[i] = Material.NetherBrickWall; + materials[5602] = Material.NetherBricks; + materials[116] = Material.NetherGoldOre; + for (int i = 4323; i <= 4324; i++) + materials[i] = Material.NetherPortal; + materials[7344] = Material.NetherQuartzOre; + materials[16183] = Material.NetherSprouts; + for (int i = 5715; i <= 5718; i++) + materials[i] = Material.NetherWart; + materials[10135] = Material.NetherWartBlock; + materials[17035] = Material.NetheriteBlock; + materials[4308] = Material.Netherrack; + for (int i = 479; i <= 1278; i++) + materials[i] = Material.NoteBlock; + for (int i = 6939; i <= 6962; i++) + materials[i] = Material.OakButton; + for (int i = 3860; i <= 3923; i++) + materials[i] = Material.OakDoor; + for (int i = 4275; i <= 4306; i++) + materials[i] = Material.OakFence; + for (int i = 5327; i <= 5358; i++) + materials[i] = Material.OakFenceGate; + for (int i = 206; i <= 233; i++) + materials[i] = Material.OakLeaves; + for (int i = 117; i <= 119; i++) + materials[i] = Material.OakLog; + materials[15] = Material.OakPlanks; + for (int i = 4178; i <= 4179; i++) + materials[i] = Material.OakPressurePlate; + for (int i = 22; i <= 23; i++) + materials[i] = Material.OakSapling; + for (int i = 3636; i <= 3667; i++) + materials[i] = Material.OakSign; + for (int i = 9041; i <= 9046; i++) + materials[i] = Material.OakSlab; + for (int i = 2208; i <= 2287; i++) + materials[i] = Material.OakStairs; + for (int i = 4420; i <= 4483; i++) + materials[i] = Material.OakTrapdoor; + for (int i = 4032; i <= 4039; i++) + materials[i] = Material.OakWallSign; + for (int i = 164; i <= 166; i++) + materials[i] = Material.OakWood; + for (int i = 10141; i <= 10152; i++) + materials[i] = Material.Observer; + materials[1688] = Material.Obsidian; + for (int i = 21437; i <= 21439; i++) + materials[i] = Material.OchreFroglight; + for (int i = 8654; i <= 8669; i++) + materials[i] = Material.OrangeBanner; + for (int i = 1295; i <= 1310; i++) + materials[i] = Material.OrangeBed; + for (int i = 18345; i <= 18360; i++) + materials[i] = Material.OrangeCandle; + for (int i = 18589; i <= 18590; i++) + materials[i] = Material.OrangeCandleCake; + materials[8608] = Material.OrangeCarpet; + materials[10320] = Material.OrangeConcrete; + materials[10336] = Material.OrangeConcretePowder; + for (int i = 10259; i <= 10262; i++) + materials[i] = Material.OrangeGlazedTerracotta; + for (int i = 10165; i <= 10170; i++) + materials[i] = Material.OrangeShulkerBox; + materials[4405] = Material.OrangeStainedGlass; + for (int i = 7524; i <= 7555; i++) + materials[i] = Material.OrangeStainedGlassPane; + materials[7477] = Material.OrangeTerracotta; + materials[1672] = Material.OrangeTulip; + for (int i = 8898; i <= 8901; i++) + materials[i] = Material.OrangeWallBanner; + materials[1639] = Material.OrangeWool; + materials[1675] = Material.OxeyeDaisy; + materials[18908] = Material.OxidizedCopper; + materials[18914] = Material.OxidizedCutCopper; + for (int i = 19238; i <= 19243; i++) + materials[i] = Material.OxidizedCutCopperSlab; + for (int i = 18918; i <= 18997; i++) + materials[i] = Material.OxidizedCutCopperStairs; + materials[8625] = Material.PackedIce; + materials[4872] = Material.PackedMud; + for (int i = 21443; i <= 21445; i++) + materials[i] = Material.PearlescentFroglight; + for (int i = 8632; i <= 8633; i++) + materials[i] = Material.Peony; + for (int i = 9107; i <= 9112; i++) + materials[i] = Material.PetrifiedOakSlab; + for (int i = 8734; i <= 8749; i++) + materials[i] = Material.PinkBanner; + for (int i = 1375; i <= 1390; i++) + materials[i] = Material.PinkBed; + for (int i = 18425; i <= 18440; i++) + materials[i] = Material.PinkCandle; + for (int i = 18599; i <= 18600; i++) + materials[i] = Material.PinkCandleCake; + materials[8613] = Material.PinkCarpet; + materials[10325] = Material.PinkConcrete; + materials[10341] = Material.PinkConcretePowder; + for (int i = 10279; i <= 10282; i++) + materials[i] = Material.PinkGlazedTerracotta; + for (int i = 10195; i <= 10200; i++) + materials[i] = Material.PinkShulkerBox; + materials[4410] = Material.PinkStainedGlass; + for (int i = 7684; i <= 7715; i++) + materials[i] = Material.PinkStainedGlassPane; + materials[7482] = Material.PinkTerracotta; + materials[1674] = Material.PinkTulip; + for (int i = 8918; i <= 8921; i++) + materials[i] = Material.PinkWallBanner; + materials[1644] = Material.PinkWool; + for (int i = 1602; i <= 1613; i++) + materials[i] = Material.Piston; + for (int i = 1614; i <= 1637; i++) + materials[i] = Material.PistonHead; + for (int i = 7167; i <= 7182; i++) + materials[i] = Material.PlayerHead; + for (int i = 7183; i <= 7186; i++) + materials[i] = Material.PlayerWallHead; + for (int i = 12; i <= 13; i++) + materials[i] = Material.Podzol; + for (int i = 19638; i <= 19657; i++) + materials[i] = Material.PointedDripstone; + materials[7] = Material.PolishedAndesite; + for (int i = 11736; i <= 11741; i++) + materials[i] = Material.PolishedAndesiteSlab; + for (int i = 11510; i <= 11589; i++) + materials[i] = Material.PolishedAndesiteStairs; + for (int i = 4314; i <= 4316; i++) + materials[i] = Material.PolishedBasalt; + materials[17459] = Material.PolishedBlackstone; + for (int i = 17463; i <= 17468; i++) + materials[i] = Material.PolishedBlackstoneBrickSlab; + for (int i = 17469; i <= 17548; i++) + materials[i] = Material.PolishedBlackstoneBrickStairs; + for (int i = 17549; i <= 17872; i++) + materials[i] = Material.PolishedBlackstoneBrickWall; + materials[17460] = Material.PolishedBlackstoneBricks; + for (int i = 17962; i <= 17985; i++) + materials[i] = Material.PolishedBlackstoneButton; + for (int i = 17960; i <= 17961; i++) + materials[i] = Material.PolishedBlackstonePressurePlate; + for (int i = 17954; i <= 17959; i++) + materials[i] = Material.PolishedBlackstoneSlab; + for (int i = 17874; i <= 17953; i++) + materials[i] = Material.PolishedBlackstoneStairs; + for (int i = 17986; i <= 18309; i++) + materials[i] = Material.PolishedBlackstoneWall; + materials[20192] = Material.PolishedDeepslate; + for (int i = 20273; i <= 20278; i++) + materials[i] = Material.PolishedDeepslateSlab; + for (int i = 20193; i <= 20272; i++) + materials[i] = Material.PolishedDeepslateStairs; + for (int i = 20279; i <= 20602; i++) + materials[i] = Material.PolishedDeepslateWall; + materials[5] = Material.PolishedDiorite; + for (int i = 11688; i <= 11693; i++) + materials[i] = Material.PolishedDioriteSlab; + for (int i = 10790; i <= 10869; i++) + materials[i] = Material.PolishedDioriteStairs; + materials[3] = Material.PolishedGranite; + for (int i = 11670; i <= 11675; i++) + materials[i] = Material.PolishedGraniteSlab; + for (int i = 10550; i <= 10629; i++) + materials[i] = Material.PolishedGraniteStairs; + materials[1667] = Material.Poppy; + for (int i = 6931; i <= 6938; i++) + materials[i] = Material.Potatoes; + materials[6902] = Material.PottedAcaciaSapling; + materials[6909] = Material.PottedAllium; + materials[21435] = Material.PottedAzaleaBush; + materials[6910] = Material.PottedAzureBluet; + materials[10545] = Material.PottedBamboo; + materials[6900] = Material.PottedBirchSapling; + materials[6908] = Material.PottedBlueOrchid; + materials[6920] = Material.PottedBrownMushroom; + materials[6922] = Material.PottedCactus; + materials[6916] = Material.PottedCornflower; + materials[17043] = Material.PottedCrimsonFungus; + materials[17045] = Material.PottedCrimsonRoots; + materials[6906] = Material.PottedDandelion; + materials[6903] = Material.PottedDarkOakSapling; + materials[6921] = Material.PottedDeadBush; + materials[6905] = Material.PottedFern; + materials[21436] = Material.PottedFloweringAzaleaBush; + materials[6901] = Material.PottedJungleSapling; + materials[6917] = Material.PottedLilyOfTheValley; + materials[6904] = Material.PottedMangrovePropagule; + materials[6898] = Material.PottedOakSapling; + materials[6912] = Material.PottedOrangeTulip; + materials[6915] = Material.PottedOxeyeDaisy; + materials[6914] = Material.PottedPinkTulip; + materials[6907] = Material.PottedPoppy; + materials[6919] = Material.PottedRedMushroom; + materials[6911] = Material.PottedRedTulip; + materials[6899] = Material.PottedSpruceSapling; + materials[17044] = Material.PottedWarpedFungus; + materials[17046] = Material.PottedWarpedRoots; + materials[6913] = Material.PottedWhiteTulip; + materials[6918] = Material.PottedWitherRose; + materials[18672] = Material.PowderSnow; + for (int i = 5733; i <= 5735; i++) + materials[i] = Material.PowderSnowCauldron; + for (int i = 1535; i <= 1558; i++) + materials[i] = Material.PoweredRail; + materials[8342] = Material.Prismarine; + for (int i = 8591; i <= 8596; i++) + materials[i] = Material.PrismarineBrickSlab; + for (int i = 8425; i <= 8504; i++) + materials[i] = Material.PrismarineBrickStairs; + materials[8343] = Material.PrismarineBricks; + for (int i = 8585; i <= 8590; i++) + materials[i] = Material.PrismarineSlab; + for (int i = 8345; i <= 8424; i++) + materials[i] = Material.PrismarineStairs; + for (int i = 12072; i <= 12395; i++) + materials[i] = Material.PrismarineWall; + materials[4307] = Material.Pumpkin; + for (int i = 5151; i <= 5158; i++) + materials[i] = Material.PumpkinStem; + for (int i = 8798; i <= 8813; i++) + materials[i] = Material.PurpleBanner; + for (int i = 1439; i <= 1454; i++) + materials[i] = Material.PurpleBed; + for (int i = 18489; i <= 18504; i++) + materials[i] = Material.PurpleCandle; + for (int i = 18607; i <= 18608; i++) + materials[i] = Material.PurpleCandleCake; + materials[8617] = Material.PurpleCarpet; + materials[10329] = Material.PurpleConcrete; + materials[10345] = Material.PurpleConcretePowder; + for (int i = 10295; i <= 10298; i++) + materials[i] = Material.PurpleGlazedTerracotta; + for (int i = 10219; i <= 10224; i++) + materials[i] = Material.PurpleShulkerBox; + materials[4414] = Material.PurpleStainedGlass; + for (int i = 7812; i <= 7843; i++) + materials[i] = Material.PurpleStainedGlassPane; + materials[7486] = Material.PurpleTerracotta; + for (int i = 8934; i <= 8937; i++) + materials[i] = Material.PurpleWallBanner; + materials[1648] = Material.PurpleWool; + materials[10015] = Material.PurpurBlock; + for (int i = 10016; i <= 10018; i++) + materials[i] = Material.PurpurPillar; + for (int i = 9161; i <= 9166; i++) + materials[i] = Material.PurpurSlab; + for (int i = 10019; i <= 10098; i++) + materials[i] = Material.PurpurStairs; + materials[7355] = Material.QuartzBlock; + materials[18312] = Material.QuartzBricks; + for (int i = 7357; i <= 7359; i++) + materials[i] = Material.QuartzPillar; + for (int i = 9143; i <= 9148; i++) + materials[i] = Material.QuartzSlab; + for (int i = 7360; i <= 7439; i++) + materials[i] = Material.QuartzStairs; + for (int i = 3932; i <= 3951; i++) + materials[i] = Material.Rail; + materials[21433] = Material.RawCopperBlock; + materials[21434] = Material.RawGoldBlock; + materials[21432] = Material.RawIronBlock; + for (int i = 8862; i <= 8877; i++) + materials[i] = Material.RedBanner; + for (int i = 1503; i <= 1518; i++) + materials[i] = Material.RedBed; + for (int i = 18553; i <= 18568; i++) + materials[i] = Material.RedCandle; + for (int i = 18615; i <= 18616; i++) + materials[i] = Material.RedCandleCake; + materials[8621] = Material.RedCarpet; + materials[10333] = Material.RedConcrete; + materials[10349] = Material.RedConcretePowder; + for (int i = 10311; i <= 10314; i++) + materials[i] = Material.RedGlazedTerracotta; + materials[1680] = Material.RedMushroom; + for (int i = 4944; i <= 5007; i++) + materials[i] = Material.RedMushroomBlock; + for (int i = 11730; i <= 11735; i++) + materials[i] = Material.RedNetherBrickSlab; + for (int i = 11430; i <= 11509; i++) + materials[i] = Material.RedNetherBrickStairs; + for (int i = 14664; i <= 14987; i++) + materials[i] = Material.RedNetherBrickWall; + materials[10136] = Material.RedNetherBricks; + materials[108] = Material.RedSand; + materials[8958] = Material.RedSandstone; + for (int i = 9149; i <= 9154; i++) + materials[i] = Material.RedSandstoneSlab; + for (int i = 8961; i <= 9040; i++) + materials[i] = Material.RedSandstoneStairs; + for (int i = 12396; i <= 12719; i++) + materials[i] = Material.RedSandstoneWall; + for (int i = 10243; i <= 10248; i++) + materials[i] = Material.RedShulkerBox; + materials[4418] = Material.RedStainedGlass; + for (int i = 7940; i <= 7971; i++) + materials[i] = Material.RedStainedGlassPane; + materials[7490] = Material.RedTerracotta; + materials[1671] = Material.RedTulip; + for (int i = 8950; i <= 8953; i++) + materials[i] = Material.RedWallBanner; + materials[1652] = Material.RedWool; + materials[7343] = Material.RedstoneBlock; + for (int i = 5747; i <= 5748; i++) + materials[i] = Material.RedstoneLamp; + for (int i = 4192; i <= 4193; i++) + materials[i] = Material.RedstoneOre; + for (int i = 4196; i <= 4197; i++) + materials[i] = Material.RedstoneTorch; + for (int i = 4198; i <= 4205; i++) + materials[i] = Material.RedstoneWallTorch; + for (int i = 2312; i <= 3607; i++) + materials[i] = Material.RedstoneWire; + materials[21447] = Material.ReinforcedDeepslate; + for (int i = 4340; i <= 4403; i++) + materials[i] = Material.Repeater; + for (int i = 10106; i <= 10117; i++) + materials[i] = Material.RepeatingCommandBlock; + for (int i = 17038; i <= 17042; i++) + materials[i] = Material.RespawnAnchor; + materials[19776] = Material.RootedDirt; + for (int i = 8630; i <= 8631; i++) + materials[i] = Material.RoseBush; + materials[107] = Material.Sand; + materials[476] = Material.Sandstone; + for (int i = 9095; i <= 9100; i++) + materials[i] = Material.SandstoneSlab; + for (int i = 5761; i <= 5840; i++) + materials[i] = Material.SandstoneStairs; + for (int i = 14988; i <= 15311; i++) + materials[i] = Material.SandstoneWall; + for (int i = 15960; i <= 15991; i++) + materials[i] = Material.Scaffolding; + materials[18769] = Material.Sculk; + for (int i = 18898; i <= 18899; i++) + materials[i] = Material.SculkCatalyst; + for (int i = 18673; i <= 18768; i++) + materials[i] = Material.SculkSensor; + for (int i = 18900; i <= 18907; i++) + materials[i] = Material.SculkShrieker; + for (int i = 18770; i <= 18897; i++) + materials[i] = Material.SculkVein; + materials[8603] = Material.SeaLantern; + for (int i = 10521; i <= 10528; i++) + materials[i] = Material.SeaPickle; + materials[1599] = Material.Seagrass; + materials[16198] = Material.Shroomlight; + for (int i = 10153; i <= 10158; i++) + materials[i] = Material.ShulkerBox; + for (int i = 7107; i <= 7122; i++) + materials[i] = Material.SkeletonSkull; + for (int i = 7123; i <= 7126; i++) + materials[i] = Material.SkeletonWallSkull; + materials[8244] = Material.SlimeBlock; + for (int i = 18657; i <= 18668; i++) + materials[i] = Material.SmallAmethystBud; + for (int i = 19758; i <= 19773; i++) + materials[i] = Material.SmallDripleaf; + materials[16054] = Material.SmithingTable; + for (int i = 16008; i <= 16015; i++) + materials[i] = Material.Smoker; + materials[21431] = Material.SmoothBasalt; + materials[9169] = Material.SmoothQuartz; + for (int i = 11712; i <= 11717; i++) + materials[i] = Material.SmoothQuartzSlab; + for (int i = 11190; i <= 11269; i++) + materials[i] = Material.SmoothQuartzStairs; + materials[9170] = Material.SmoothRedSandstone; + for (int i = 11676; i <= 11681; i++) + materials[i] = Material.SmoothRedSandstoneSlab; + for (int i = 10630; i <= 10709; i++) + materials[i] = Material.SmoothRedSandstoneStairs; + materials[9168] = Material.SmoothSandstone; + for (int i = 11706; i <= 11711; i++) + materials[i] = Material.SmoothSandstoneSlab; + for (int i = 11110; i <= 11189; i++) + materials[i] = Material.SmoothSandstoneStairs; + materials[9167] = Material.SmoothStone; + for (int i = 9089; i <= 9094; i++) + materials[i] = Material.SmoothStoneSlab; + for (int i = 4230; i <= 4237; i++) + materials[i] = Material.Snow; + materials[4239] = Material.SnowBlock; + for (int i = 16131; i <= 16162; i++) + materials[i] = Material.SoulCampfire; + materials[2206] = Material.SoulFire; + for (int i = 16095; i <= 16098; i++) + materials[i] = Material.SoulLantern; + materials[4309] = Material.SoulSand; + materials[4310] = Material.SoulSoil; + materials[4317] = Material.SoulTorch; + for (int i = 4318; i <= 4321; i++) + materials[i] = Material.SoulWallTorch; + materials[2207] = Material.Spawner; + materials[458] = Material.Sponge; + materials[19713] = Material.SporeBlossom; + for (int i = 6963; i <= 6986; i++) + materials[i] = Material.SpruceButton; + for (int i = 9555; i <= 9618; i++) + materials[i] = Material.SpruceDoor; + for (int i = 9363; i <= 9394; i++) + materials[i] = Material.SpruceFence; + for (int i = 9171; i <= 9202; i++) + materials[i] = Material.SpruceFenceGate; + for (int i = 234; i <= 261; i++) + materials[i] = Material.SpruceLeaves; + for (int i = 120; i <= 122; i++) + materials[i] = Material.SpruceLog; + materials[16] = Material.SprucePlanks; + for (int i = 4180; i <= 4181; i++) + materials[i] = Material.SprucePressurePlate; + for (int i = 24; i <= 25; i++) + materials[i] = Material.SpruceSapling; + for (int i = 3668; i <= 3699; i++) + materials[i] = Material.SpruceSign; + for (int i = 9047; i <= 9052; i++) + materials[i] = Material.SpruceSlab; + for (int i = 5996; i <= 6075; i++) + materials[i] = Material.SpruceStairs; + for (int i = 4484; i <= 4547; i++) + materials[i] = Material.SpruceTrapdoor; + for (int i = 4040; i <= 4047; i++) + materials[i] = Material.SpruceWallSign; + for (int i = 167; i <= 169; i++) + materials[i] = Material.SpruceWood; + for (int i = 1583; i <= 1594; i++) + materials[i] = Material.StickyPiston; + materials[1] = Material.Stone; + for (int i = 9125; i <= 9130; i++) + materials[i] = Material.StoneBrickSlab; + for (int i = 5439; i <= 5518; i++) + materials[i] = Material.StoneBrickStairs; + for (int i = 13368; i <= 13691; i++) + materials[i] = Material.StoneBrickWall; + materials[4868] = Material.StoneBricks; + for (int i = 4206; i <= 4229; i++) + materials[i] = Material.StoneButton; + for (int i = 4112; i <= 4113; i++) + materials[i] = Material.StonePressurePlate; + for (int i = 9083; i <= 9088; i++) + materials[i] = Material.StoneSlab; + for (int i = 11030; i <= 11109; i++) + materials[i] = Material.StoneStairs; + for (int i = 16055; i <= 16058; i++) + materials[i] = Material.Stonecutter; + for (int i = 152; i <= 154; i++) + materials[i] = Material.StrippedAcaciaLog; + for (int i = 197; i <= 199; i++) + materials[i] = Material.StrippedAcaciaWood; + for (int i = 146; i <= 148; i++) + materials[i] = Material.StrippedBirchLog; + for (int i = 191; i <= 193; i++) + materials[i] = Material.StrippedBirchWood; + for (int i = 16193; i <= 16195; i++) + materials[i] = Material.StrippedCrimsonHyphae; + for (int i = 16187; i <= 16189; i++) + materials[i] = Material.StrippedCrimsonStem; + for (int i = 155; i <= 157; i++) + materials[i] = Material.StrippedDarkOakLog; + for (int i = 200; i <= 202; i++) + materials[i] = Material.StrippedDarkOakWood; + for (int i = 149; i <= 151; i++) + materials[i] = Material.StrippedJungleLog; + for (int i = 194; i <= 196; i++) + materials[i] = Material.StrippedJungleWood; + for (int i = 161; i <= 163; i++) + materials[i] = Material.StrippedMangroveLog; + for (int i = 203; i <= 205; i++) + materials[i] = Material.StrippedMangroveWood; + for (int i = 158; i <= 160; i++) + materials[i] = Material.StrippedOakLog; + for (int i = 185; i <= 187; i++) + materials[i] = Material.StrippedOakWood; + for (int i = 143; i <= 145; i++) + materials[i] = Material.StrippedSpruceLog; + for (int i = 188; i <= 190; i++) + materials[i] = Material.StrippedSpruceWood; + for (int i = 16176; i <= 16178; i++) + materials[i] = Material.StrippedWarpedHyphae; + for (int i = 16170; i <= 16172; i++) + materials[i] = Material.StrippedWarpedStem; + for (int i = 16944; i <= 16947; i++) + materials[i] = Material.StructureBlock; + materials[10140] = Material.StructureVoid; + for (int i = 4257; i <= 4272; i++) + materials[i] = Material.SugarCane; + for (int i = 8626; i <= 8627; i++) + materials[i] = Material.Sunflower; + for (int i = 16163; i <= 16166; i++) + materials[i] = Material.SweetBerryBush; + for (int i = 8634; i <= 8635; i++) + materials[i] = Material.TallGrass; + for (int i = 1600; i <= 1601; i++) + materials[i] = Material.TallSeagrass; + for (int i = 16969; i <= 16984; i++) + materials[i] = Material.Target; + materials[8623] = Material.Terracotta; + materials[18671] = Material.TintedGlass; + for (int i = 1684; i <= 1685; i++) + materials[i] = Material.Tnt; + materials[1689] = Material.Torch; + for (int i = 7239; i <= 7262; i++) + materials[i] = Material.TrappedChest; + for (int i = 5867; i <= 5994; i++) + materials[i] = Material.Tripwire; + for (int i = 5851; i <= 5866; i++) + materials[i] = Material.TripwireHook; + for (int i = 10411; i <= 10412; i++) + materials[i] = Material.TubeCoral; + materials[10396] = Material.TubeCoralBlock; + for (int i = 10431; i <= 10432; i++) + materials[i] = Material.TubeCoralFan; + for (int i = 10481; i <= 10488; i++) + materials[i] = Material.TubeCoralWallFan; + materials[18669] = Material.Tuff; + for (int i = 10379; i <= 10390; i++) + materials[i] = Material.TurtleEgg; + for (int i = 16226; i <= 16251; i++) + materials[i] = Material.TwistingVines; + materials[16252] = Material.TwistingVinesPlant; + for (int i = 21440; i <= 21442; i++) + materials[i] = Material.VerdantFroglight; + for (int i = 5167; i <= 5198; i++) + materials[i] = Material.Vine; + materials[10546] = Material.VoidAir; + for (int i = 1690; i <= 1693; i++) + materials[i] = Material.WallTorch; + for (int i = 16712; i <= 16735; i++) + materials[i] = Material.WarpedButton; + for (int i = 16800; i <= 16863; i++) + materials[i] = Material.WarpedDoor; + for (int i = 16304; i <= 16335; i++) + materials[i] = Material.WarpedFence; + for (int i = 16496; i <= 16527; i++) + materials[i] = Material.WarpedFenceGate; + materials[16180] = Material.WarpedFungus; + for (int i = 16173; i <= 16175; i++) + materials[i] = Material.WarpedHyphae; + materials[16179] = Material.WarpedNylium; + materials[16255] = Material.WarpedPlanks; + for (int i = 16270; i <= 16271; i++) + materials[i] = Material.WarpedPressurePlate; + materials[16182] = Material.WarpedRoots; + for (int i = 16896; i <= 16927; i++) + materials[i] = Material.WarpedSign; + for (int i = 16262; i <= 16267; i++) + materials[i] = Material.WarpedSlab; + for (int i = 16608; i <= 16687; i++) + materials[i] = Material.WarpedStairs; + for (int i = 16167; i <= 16169; i++) + materials[i] = Material.WarpedStem; + for (int i = 16400; i <= 16463; i++) + materials[i] = Material.WarpedTrapdoor; + for (int i = 16936; i <= 16943; i++) + materials[i] = Material.WarpedWallSign; + materials[16181] = Material.WarpedWartBlock; + for (int i = 75; i <= 90; i++) + materials[i] = Material.Water; + for (int i = 5729; i <= 5731; i++) + materials[i] = Material.WaterCauldron; + materials[19262] = Material.WaxedCopperBlock; + materials[19269] = Material.WaxedCutCopper; + for (int i = 19608; i <= 19613; i++) + materials[i] = Material.WaxedCutCopperSlab; + for (int i = 19510; i <= 19589; i++) + materials[i] = Material.WaxedCutCopperStairs; + materials[19264] = Material.WaxedExposedCopper; + materials[19268] = Material.WaxedExposedCutCopper; + for (int i = 19602; i <= 19607; i++) + materials[i] = Material.WaxedExposedCutCopperSlab; + for (int i = 19430; i <= 19509; i++) + materials[i] = Material.WaxedExposedCutCopperStairs; + materials[19265] = Material.WaxedOxidizedCopper; + materials[19266] = Material.WaxedOxidizedCutCopper; + for (int i = 19590; i <= 19595; i++) + materials[i] = Material.WaxedOxidizedCutCopperSlab; + for (int i = 19270; i <= 19349; i++) + materials[i] = Material.WaxedOxidizedCutCopperStairs; + materials[19263] = Material.WaxedWeatheredCopper; + materials[19267] = Material.WaxedWeatheredCutCopper; + for (int i = 19596; i <= 19601; i++) + materials[i] = Material.WaxedWeatheredCutCopperSlab; + for (int i = 19350; i <= 19429; i++) + materials[i] = Material.WaxedWeatheredCutCopperStairs; + materials[18909] = Material.WeatheredCopper; + materials[18915] = Material.WeatheredCutCopper; + for (int i = 19244; i <= 19249; i++) + materials[i] = Material.WeatheredCutCopperSlab; + for (int i = 18998; i <= 19077; i++) + materials[i] = Material.WeatheredCutCopperStairs; + for (int i = 16199; i <= 16224; i++) + materials[i] = Material.WeepingVines; + materials[16225] = Material.WeepingVinesPlant; + materials[459] = Material.WetSponge; + for (int i = 3612; i <= 3619; i++) + materials[i] = Material.Wheat; + for (int i = 8638; i <= 8653; i++) + materials[i] = Material.WhiteBanner; + for (int i = 1279; i <= 1294; i++) + materials[i] = Material.WhiteBed; + for (int i = 18329; i <= 18344; i++) + materials[i] = Material.WhiteCandle; + for (int i = 18587; i <= 18588; i++) + materials[i] = Material.WhiteCandleCake; + materials[8607] = Material.WhiteCarpet; + materials[10319] = Material.WhiteConcrete; + materials[10335] = Material.WhiteConcretePowder; + for (int i = 10255; i <= 10258; i++) + materials[i] = Material.WhiteGlazedTerracotta; + for (int i = 10159; i <= 10164; i++) + materials[i] = Material.WhiteShulkerBox; + materials[4404] = Material.WhiteStainedGlass; + for (int i = 7492; i <= 7523; i++) + materials[i] = Material.WhiteStainedGlassPane; + materials[7476] = Material.WhiteTerracotta; + materials[1673] = Material.WhiteTulip; + for (int i = 8894; i <= 8897; i++) + materials[i] = Material.WhiteWallBanner; + materials[1638] = Material.WhiteWool; + materials[1677] = Material.WitherRose; + for (int i = 7127; i <= 7142; i++) + materials[i] = Material.WitherSkeletonSkull; + for (int i = 7143; i <= 7146; i++) + materials[i] = Material.WitherSkeletonWallSkull; + for (int i = 8702; i <= 8717; i++) + materials[i] = Material.YellowBanner; + for (int i = 1343; i <= 1358; i++) + materials[i] = Material.YellowBed; + for (int i = 18393; i <= 18408; i++) + materials[i] = Material.YellowCandle; + for (int i = 18595; i <= 18596; i++) + materials[i] = Material.YellowCandleCake; + materials[8611] = Material.YellowCarpet; + materials[10323] = Material.YellowConcrete; + materials[10339] = Material.YellowConcretePowder; + for (int i = 10271; i <= 10274; i++) + materials[i] = Material.YellowGlazedTerracotta; + for (int i = 10183; i <= 10188; i++) + materials[i] = Material.YellowShulkerBox; + materials[4408] = Material.YellowStainedGlass; + for (int i = 7620; i <= 7651; i++) + materials[i] = Material.YellowStainedGlassPane; + materials[7480] = Material.YellowTerracotta; + for (int i = 8910; i <= 8913; i++) + materials[i] = Material.YellowWallBanner; + materials[1642] = Material.YellowWool; + for (int i = 7147; i <= 7162; i++) + materials[i] = Material.ZombieHead; + for (int i = 7163; i <= 7166; i++) + materials[i] = Material.ZombieWallHead; + } + + protected override Dictionary GetDict() + { + return materials; + } + } +} diff --git a/MinecraftClient/Mapping/EntityPalettes/EntityPalette119.cs b/MinecraftClient/Mapping/EntityPalettes/EntityPalette119.cs new file mode 100644 index 00000000..b85059cc --- /dev/null +++ b/MinecraftClient/Mapping/EntityPalettes/EntityPalette119.cs @@ -0,0 +1,137 @@ +using System; +using System.Collections.Generic; + +namespace MinecraftClient.Mapping.EntityPalettes +{ + public class EntityPalette119 : EntityPalette + { + private static Dictionary mappings = new Dictionary(); + + static EntityPalette119() + { + mappings[0] = EntityType.Allay; + mappings[1] = EntityType.AreaEffectCloud; + mappings[2] = EntityType.ArmorStand; + mappings[3] = EntityType.Arrow; + mappings[4] = EntityType.Axolotl; + mappings[5] = EntityType.Bat; + mappings[6] = EntityType.Bee; + mappings[7] = EntityType.Blaze; + mappings[8] = EntityType.Boat; + mappings[10] = EntityType.Cat; + mappings[11] = EntityType.CaveSpider; + mappings[9] = EntityType.ChestBoat; + mappings[54] = EntityType.ChestMinecart; + mappings[12] = EntityType.Chicken; + mappings[13] = EntityType.Cod; + mappings[55] = EntityType.CommandBlockMinecart; + mappings[14] = EntityType.Cow; + mappings[15] = EntityType.Creeper; + mappings[16] = EntityType.Dolphin; + mappings[17] = EntityType.Donkey; + mappings[18] = EntityType.DragonFireball; + mappings[19] = EntityType.Drowned; + mappings[93] = EntityType.Egg; + mappings[20] = EntityType.ElderGuardian; + mappings[21] = EntityType.EndCrystal; + mappings[22] = EntityType.EnderDragon; + mappings[94] = EntityType.EnderPearl; + mappings[23] = EntityType.Enderman; + mappings[24] = EntityType.Endermite; + mappings[25] = EntityType.Evoker; + mappings[26] = EntityType.EvokerFangs; + mappings[95] = EntityType.ExperienceBottle; + mappings[27] = EntityType.ExperienceOrb; + mappings[28] = EntityType.EyeOfEnder; + mappings[29] = EntityType.FallingBlock; + mappings[46] = EntityType.Fireball; + mappings[30] = EntityType.FireworkRocket; + mappings[117] = EntityType.FishingBobber; + mappings[31] = EntityType.Fox; + mappings[32] = EntityType.Frog; + mappings[56] = EntityType.FurnaceMinecart; + mappings[33] = EntityType.Ghast; + mappings[34] = EntityType.Giant; + mappings[35] = EntityType.GlowItemFrame; + mappings[36] = EntityType.GlowSquid; + mappings[37] = EntityType.Goat; + mappings[38] = EntityType.Guardian; + mappings[39] = EntityType.Hoglin; + mappings[57] = EntityType.HopperMinecart; + mappings[40] = EntityType.Horse; + mappings[41] = EntityType.Husk; + mappings[42] = EntityType.Illusioner; + mappings[43] = EntityType.IronGolem; + mappings[44] = EntityType.Item; + mappings[45] = EntityType.ItemFrame; + mappings[47] = EntityType.LeashKnot; + mappings[48] = EntityType.LightningBolt; + mappings[49] = EntityType.Llama; + mappings[50] = EntityType.LlamaSpit; + mappings[51] = EntityType.MagmaCube; + mappings[52] = EntityType.Marker; + mappings[53] = EntityType.Minecart; + mappings[61] = EntityType.Mooshroom; + mappings[60] = EntityType.Mule; + mappings[62] = EntityType.Ocelot; + mappings[63] = EntityType.Painting; + mappings[64] = EntityType.Panda; + mappings[65] = EntityType.Parrot; + mappings[66] = EntityType.Phantom; + mappings[67] = EntityType.Pig; + mappings[68] = EntityType.Piglin; + mappings[69] = EntityType.PiglinBrute; + mappings[70] = EntityType.Pillager; + mappings[116] = EntityType.Player; + mappings[71] = EntityType.PolarBear; + mappings[96] = EntityType.Potion; + mappings[73] = EntityType.Pufferfish; + mappings[74] = EntityType.Rabbit; + mappings[75] = EntityType.Ravager; + mappings[76] = EntityType.Salmon; + mappings[77] = EntityType.Sheep; + mappings[78] = EntityType.Shulker; + mappings[79] = EntityType.ShulkerBullet; + mappings[80] = EntityType.Silverfish; + mappings[81] = EntityType.Skeleton; + mappings[82] = EntityType.SkeletonHorse; + mappings[83] = EntityType.Slime; + mappings[84] = EntityType.SmallFireball; + mappings[85] = EntityType.SnowGolem; + mappings[86] = EntityType.Snowball; + mappings[58] = EntityType.SpawnerMinecart; + mappings[87] = EntityType.SpectralArrow; + mappings[88] = EntityType.Spider; + mappings[89] = EntityType.Squid; + mappings[90] = EntityType.Stray; + mappings[91] = EntityType.Strider; + mappings[92] = EntityType.Tadpole; + mappings[72] = EntityType.Tnt; + mappings[59] = EntityType.TntMinecart; + mappings[98] = EntityType.TraderLlama; + mappings[97] = EntityType.Trident; + mappings[99] = EntityType.TropicalFish; + mappings[100] = EntityType.Turtle; + mappings[101] = EntityType.Vex; + mappings[102] = EntityType.Villager; + mappings[103] = EntityType.Vindicator; + mappings[104] = EntityType.WanderingTrader; + mappings[105] = EntityType.Warden; + mappings[106] = EntityType.Witch; + mappings[107] = EntityType.Wither; + mappings[108] = EntityType.WitherSkeleton; + mappings[109] = EntityType.WitherSkull; + mappings[110] = EntityType.Wolf; + mappings[111] = EntityType.Zoglin; + mappings[112] = EntityType.Zombie; + mappings[113] = EntityType.ZombieHorse; + mappings[114] = EntityType.ZombieVillager; + mappings[115] = EntityType.ZombifiedPiglin; + } + + protected override Dictionary GetDict() + { + return mappings; + } + } +} diff --git a/MinecraftClient/Mapping/EntityType.cs b/MinecraftClient/Mapping/EntityType.cs index a0368e98..43bb89da 100644 --- a/MinecraftClient/Mapping/EntityType.cs +++ b/MinecraftClient/Mapping/EntityType.cs @@ -4,16 +4,17 @@ namespace MinecraftClient.Mapping /// Represents Minecraft Entity Types /// /// - /// Generated from registries.json using EntityPaletteGenerator.cs. + /// Generated from registries.json using the --generator flag on the client /// Typical steps to handle new entity IDs for newer Minecraft versions: - /// 1. Generate registries.json using data reporting on Vanilla Minecraft (https://wiki.vg/Data_Generators) - /// 2. Generate temporary EntityTypeXXX.cs and EntityPaletteXXX.cs using EntityPaletteGenerator.cs + /// 1. Generate registries.json using data reporting on Vanilla Minecraft (https://wiki.vg/Data_Generators) or download it from: https://github.com/PixiGeko/Minecraft-generated-data + /// 2. Generate temporary EntityTypeXXX.cs and EntityPaletteXXX.cs using the --generator flag on the client /// 3. Perform a diff with existing versions, add missing entries in EntityType.cs and EntityTypeExtensions.cs /// 4. If existing entity IDs were not randomized by Mojang, simply add missing entries to the latest existing EntityPaletteXXX.cs /// 5. If existing entity IDs were randomized, add a new palette as EntityPaletteXXX.cs into the codebase (worst case) /// public enum EntityType { + Allay, AreaEffectCloud, ArmorStand, Arrow, @@ -24,6 +25,7 @@ namespace MinecraftClient.Mapping Boat, Cat, CaveSpider, + ChestBoat, ChestMinecart, Chicken, Cod, @@ -38,9 +40,9 @@ namespace MinecraftClient.Mapping ElderGuardian, EndCrystal, EnderDragon, + EnderPearl, Enderman, Endermite, - EnderPearl, Evoker, EvokerFangs, ExperienceBottle, @@ -51,6 +53,7 @@ namespace MinecraftClient.Mapping FireworkRocket, FishingBobber, Fox, + Frog, FurnaceMinecart, Ghast, Giant, @@ -99,14 +102,15 @@ namespace MinecraftClient.Mapping SkeletonHorse, Slime, SmallFireball, - Snowball, SnowGolem, + Snowball, SpawnerMinecart, SpectralArrow, Spider, Squid, Stray, Strider, + Tadpole, Tnt, TntMinecart, TraderLlama, @@ -117,6 +121,7 @@ namespace MinecraftClient.Mapping Villager, Vindicator, WanderingTrader, + Warden, Witch, Wither, WitherSkeleton, diff --git a/MinecraftClient/Mapping/Material.cs b/MinecraftClient/Mapping/Material.cs index ea5cc704..507dcc56 100644 --- a/MinecraftClient/Mapping/Material.cs +++ b/MinecraftClient/Mapping/Material.cs @@ -4,10 +4,10 @@ /// Represents Minecraft Materials /// /// - /// Generated from blocks.json using BlockPaletteGenerator.cs. + /// Generated from blocks.json using the --generator flag on the client /// Typical steps to handle new blocks for newer Minecraft versions: - /// 1. Generate blocks.json using data reporting on Vanilla Minecraft (https://wiki.vg/Data_Generators) - /// 2. Generate temporary MaterialXXX.cs and PaletteXXX.cs using BlockPaletteGenerator.cs + /// 1. Generate blocks.json using data reporting on Vanilla Minecraft (https://wiki.vg/Data_Generators) or download it from: https://github.com/PixiGeko/Minecraft-generated-data + /// 2. Generate temporary MaterialXXX.cs and PaletteXXX.cs using the --generator flag on the client /// 3. Perform a diff with existing versions, add missing entries in Material.cs and MaterialExtensions.cs /// 4. If existing state IDs were not randomized by Mojang, simply add missing state entries to Palette113.cs /// 5. If existing state IDs were randomized, add a new palette as PaletteXXX.cs into the codebase (worst case) @@ -52,8 +52,8 @@ Basalt, Beacon, Bedrock, - Beehive, BeeNest, + Beehive, Beetroots, Bell, BigDripleaf, @@ -84,13 +84,13 @@ BlackShulkerBox, BlackStainedGlass, BlackStainedGlassPane, + BlackTerracotta, + BlackWallBanner, + BlackWool, Blackstone, BlackstoneSlab, BlackstoneStairs, BlackstoneWall, - BlackTerracotta, - BlackWallBanner, - BlackWool, BlastFurnace, BlueBanner, BlueBed, @@ -115,10 +115,10 @@ BrainCoralFan, BrainCoralWallFan, BrewingStand, - Bricks, BrickSlab, BrickStairs, BrickWall, + Bricks, BrownBanner, BrownBed, BrownCandle, @@ -277,10 +277,10 @@ DeadTubeCoralFan, DeadTubeCoralWallFan, Deepslate, - DeepslateBricks, DeepslateBrickSlab, DeepslateBrickStairs, DeepslateBrickWall, + DeepslateBricks, DeepslateCoalOre, DeepslateCopperOre, DeepslateDiamondOre, @@ -289,10 +289,10 @@ DeepslateIronOre, DeepslateLapisOre, DeepslateRedstoneOre, - DeepslateTiles, DeepslateTileSlab, DeepslateTileStairs, DeepslateTileWall, + DeepslateTiles, DetectorRail, DiamondBlock, DiamondOre, @@ -301,6 +301,7 @@ DioriteStairs, DioriteWall, Dirt, + DirtPath, Dispenser, DragonEgg, DragonHead, @@ -311,16 +312,16 @@ EmeraldBlock, EmeraldOre, EnchantingTable, - EnderChest, EndGateway, EndPortal, EndPortalFrame, EndRod, EndStone, - EndStoneBricks, EndStoneBrickSlab, EndStoneBrickStairs, EndStoneBrickWall, + EndStoneBricks, + EnderChest, ExposedCopper, ExposedCutCopper, ExposedCutCopperSlab, @@ -333,9 +334,10 @@ FireCoralFan, FireCoralWallFan, FletchingTable, + FlowerPot, FloweringAzalea, FloweringAzaleaLeaves, - FlowerPot, + Frogspawn, FrostedIce, Furnace, GildedBlackstone, @@ -351,7 +353,6 @@ GraniteWall, Grass, GrassBlock, - GrassPath, Gravel, GrayBanner, GrayBed, @@ -464,8 +465,8 @@ LightGrayTerracotta, LightGrayWallBanner, LightGrayWool, - LightningRod, LightWeightedPressurePlate, + LightningRod, Lilac, LilyOfTheValley, LilyPad, @@ -500,6 +501,22 @@ MagentaWallBanner, MagentaWool, MagmaBlock, + MangroveButton, + MangroveDoor, + MangroveFence, + MangroveFenceGate, + MangroveLeaves, + MangroveLog, + MangrovePlanks, + MangrovePressurePlate, + MangrovePropagule, + MangroveRoots, + MangroveSign, + MangroveSlab, + MangroveStairs, + MangroveTrapdoor, + MangroveWallSign, + MangroveWood, MediumAmethystBud, Melon, MelonStem, @@ -509,26 +526,32 @@ MossyCobblestoneSlab, MossyCobblestoneStairs, MossyCobblestoneWall, - MossyStoneBricks, MossyStoneBrickSlab, MossyStoneBrickStairs, MossyStoneBrickWall, + MossyStoneBricks, MovingPiston, + Mud, + MudBrickSlab, + MudBrickStairs, + MudBrickWall, + MudBricks, + MuddyMangroveRoots, MushroomStem, Mycelium, NetherBrickFence, - NetherBricks, NetherBrickSlab, NetherBrickStairs, NetherBrickWall, + NetherBricks, NetherGoldOre, - NetheriteBlock, NetherPortal, NetherQuartzOre, - Netherrack, NetherSprouts, NetherWart, NetherWartBlock, + NetheriteBlock, + Netherrack, NoteBlock, OakButton, OakDoor, @@ -547,6 +570,7 @@ OakWood, Observer, Obsidian, + OchreFroglight, OrangeBanner, OrangeBed, OrangeCandle, @@ -568,6 +592,8 @@ OxidizedCutCopperSlab, OxidizedCutCopperStairs, PackedIce, + PackedMud, + PearlescentFroglight, Peony, PetrifiedOakSlab, PinkBanner, @@ -596,10 +622,10 @@ PolishedAndesiteStairs, PolishedBasalt, PolishedBlackstone, - PolishedBlackstoneBricks, PolishedBlackstoneBrickSlab, PolishedBlackstoneBrickStairs, PolishedBlackstoneBrickWall, + PolishedBlackstoneBricks, PolishedBlackstoneButton, PolishedBlackstonePressurePlate, PolishedBlackstoneSlab, @@ -636,6 +662,7 @@ PottedFloweringAzaleaBush, PottedJungleSapling, PottedLilyOfTheValley, + PottedMangrovePropagule, PottedOakSapling, PottedOrangeTulip, PottedOxeyeDaisy, @@ -652,9 +679,9 @@ PowderSnowCauldron, PoweredRail, Prismarine, - PrismarineBricks, PrismarineBrickSlab, PrismarineBrickStairs, + PrismarineBricks, PrismarineSlab, PrismarineStairs, PrismarineWall, @@ -697,10 +724,10 @@ RedGlazedTerracotta, RedMushroom, RedMushroomBlock, - RedNetherBricks, RedNetherBrickSlab, RedNetherBrickStairs, RedNetherBrickWall, + RedNetherBricks, RedSand, RedSandstone, RedSandstoneSlab, @@ -709,16 +736,17 @@ RedShulkerBox, RedStainedGlass, RedStainedGlassPane, + RedTerracotta, + RedTulip, + RedWallBanner, + RedWool, RedstoneBlock, RedstoneLamp, RedstoneOre, RedstoneTorch, RedstoneWallTorch, RedstoneWire, - RedTerracotta, - RedTulip, - RedWallBanner, - RedWool, + ReinforcedDeepslate, Repeater, RepeatingCommandBlock, RespawnAnchor, @@ -730,10 +758,14 @@ SandstoneStairs, SandstoneWall, Scaffolding, + Sculk, + SculkCatalyst, SculkSensor, - Seagrass, + SculkShrieker, + SculkVein, SeaLantern, SeaPickle, + Seagrass, Shroomlight, ShulkerBox, SkeletonSkull, @@ -784,15 +816,15 @@ SpruceWood, StickyPiston, Stone, - StoneBricks, StoneBrickSlab, StoneBrickStairs, StoneBrickWall, + StoneBricks, StoneButton, - Stonecutter, StonePressurePlate, StoneSlab, StoneStairs, + Stonecutter, StrippedAcaciaLog, StrippedAcaciaWood, StrippedBirchLog, @@ -803,6 +835,8 @@ StrippedDarkOakWood, StrippedJungleLog, StrippedJungleWood, + StrippedMangroveLog, + StrippedMangroveWood, StrippedOakLog, StrippedOakWood, StrippedSpruceLog, @@ -832,6 +866,7 @@ TurtleEgg, TwistingVines, TwistingVinesPlant, + VerdantFroglight, Vine, VoidAir, WallTorch, diff --git a/MinecraftClient/Mapping/Material2Tool.cs b/MinecraftClient/Mapping/Material2Tool.cs index d8433808..f2259d0f 100644 --- a/MinecraftClient/Mapping/Material2Tool.cs +++ b/MinecraftClient/Mapping/Material2Tool.cs @@ -367,7 +367,7 @@ namespace MinecraftClient.Mapping Material.Farmland, Material.Grass, Material.GrassBlock, - Material.GrassPath, + Material.DirtPath, Material.Gravel, Material.GrayConcretePowder, Material.GreenConcretePowder, diff --git a/MinecraftClient/Mapping/MaterialExtensions.cs b/MinecraftClient/Mapping/MaterialExtensions.cs index 391097f6..39f9e51a 100644 --- a/MinecraftClient/Mapping/MaterialExtensions.cs +++ b/MinecraftClient/Mapping/MaterialExtensions.cs @@ -372,7 +372,7 @@ namespace MinecraftClient.Mapping case Material.PurpurPillar: case Material.PurpurStairs: case Material.EndStoneBricks: - case Material.GrassPath: + case Material.DirtPath: case Material.RepeatingCommandBlock: case Material.ChainCommandBlock: case Material.FrostedIce: diff --git a/MinecraftClient/Protocol/Handlers/DataTypes.cs b/MinecraftClient/Protocol/Handlers/DataTypes.cs index 624924ab..320657e8 100644 --- a/MinecraftClient/Protocol/Handlers/DataTypes.cs +++ b/MinecraftClient/Protocol/Handlers/DataTypes.cs @@ -403,13 +403,13 @@ namespace MinecraftClient.Protocol.Handlers Double entityX = ReadNextDouble(cache); Double entityY = ReadNextDouble(cache); Double entityZ = ReadNextDouble(cache); - byte entityYaw = ReadNextByte(cache); byte entityPitch = ReadNextByte(cache); + byte entityYaw = ReadNextByte(cache); int metadata = -1; if (living) { - if (protocolversion >= Protocol18Handler.MC_1_18_2_Version) + if (protocolversion == Protocol18Handler.MC_1_18_2_Version) entityYaw = ReadNextByte(cache); else entityPitch = ReadNextByte(cache); @@ -418,15 +418,17 @@ namespace MinecraftClient.Protocol.Handlers { if (protocolversion >= Protocol18Handler.MC_1_19_Version) { - metadata = ReadNextVarInt(cache); entityYaw = ReadNextByte(cache); + metadata = ReadNextVarInt(cache); } else metadata = ReadNextInt(cache); } + short velocityX = ReadNextShort(cache); short velocityY = ReadNextShort(cache); short velocityZ = ReadNextShort(cache); + return new Entity(entityID, entityType, new Location(entityX, entityY, entityZ), entityYaw, entityPitch, metadata); } diff --git a/MinecraftClient/Protocol/Handlers/Protocol18.cs b/MinecraftClient/Protocol/Handlers/Protocol18.cs index ecb3dfed..a961990c 100644 --- a/MinecraftClient/Protocol/Handlers/Protocol18.cs +++ b/MinecraftClient/Protocol/Handlers/Protocol18.cs @@ -23,7 +23,7 @@ using System.Text.RegularExpressions; namespace MinecraftClient.Protocol.Handlers { /// - /// Implementation for Minecraft 1.7.X+ Protocols + /// Implementation for Minecraft 1.8.X+ Protocols /// /// /// Typical update steps for implementing protocol changes for a new Minecraft version: @@ -62,7 +62,7 @@ namespace MinecraftClient.Protocol.Handlers private readonly List autocomplete_result = new List(); private readonly Dictionary window_actions = new Dictionary(); private bool login_phase = true; - private int protocolversion; + private int protocolVersion; private int currentDimension; Protocol18Forge pForge; @@ -83,7 +83,7 @@ namespace MinecraftClient.Protocol.Handlers ChatParser.InitTranslations(); this.socketWrapper = new SocketWrapper(Client); this.dataTypes = new DataTypes(protocolVersion); - this.protocolversion = protocolVersion; + this.protocolVersion = protocolVersion; this.handler = handler; this.pForge = new Protocol18Forge(forgeInfo, protocolVersion, dataTypes, this, handler); this.pTerrain = new Protocol18Terrain(protocolVersion, dataTypes, handler); @@ -91,73 +91,81 @@ namespace MinecraftClient.Protocol.Handlers this.log = handler.GetLogger(); this.randomGen = RandomNumberGenerator.Create(); - if (handler.GetTerrainEnabled() && protocolversion > MC_1_18_2_Version) + if (handler.GetTerrainEnabled() && protocolVersion > MC_1_18_2_Version) { log.Error(Translations.Get("extra.terrainandmovement_disabled")); handler.SetTerrainEnabled(false); } - if (handler.GetInventoryEnabled() && (protocolversion < MC_1_10_Version || protocolversion > MC_1_18_2_Version)) + if (handler.GetInventoryEnabled() && (protocolVersion < MC_1_10_Version || protocolVersion > MC_1_19_Version)) { log.Error(Translations.Get("extra.inventory_disabled")); handler.SetInventoryEnabled(false); } - if (handler.GetEntityHandlingEnabled() && (protocolversion < MC_1_10_Version || protocolversion > MC_1_18_2_Version)) + if (handler.GetEntityHandlingEnabled() && (protocolVersion < MC_1_10_Version || protocolVersion > MC_1_19_Version)) { log.Error(Translations.Get("extra.entity_disabled")); handler.SetEntityHandlingEnabled(false); } // Block palette - if (protocolversion >= MC_1_13_Version) + if (protocolVersion >= MC_1_13_Version) { - if (protocolVersion > MC_1_18_2_Version && handler.GetTerrainEnabled()) + if (protocolVersion > MC_1_19_Version && handler.GetTerrainEnabled()) throw new NotImplementedException(Translations.Get("exception.palette.block")); - if (protocolVersion >= MC_1_17_Version) + + if (protocolVersion == MC_1_19_Version) + Block.Palette = new Palette119(); + else if (protocolVersion >= MC_1_17_Version) Block.Palette = new Palette117(); else if (protocolVersion >= MC_1_16_Version) - if (protocolVersion >= MC_1_16_Version) - Block.Palette = new Palette116(); - else if (protocolVersion >= MC_1_15_Version) - Block.Palette = new Palette115(); - else if (protocolVersion >= MC_1_14_Version) - Block.Palette = new Palette114(); - else Block.Palette = new Palette113(); + Block.Palette = new Palette116(); + else if (protocolVersion >= MC_1_15_Version) + Block.Palette = new Palette115(); + else if (protocolVersion >= MC_1_14_Version) + Block.Palette = new Palette114(); + else Block.Palette = new Palette113(); + } else Block.Palette = new Palette112(); // Entity palette - if (protocolversion >= MC_1_13_Version) + if (protocolVersion >= MC_1_13_Version) { - if (protocolversion > MC_1_18_2_Version && handler.GetEntityHandlingEnabled()) + if (protocolVersion > MC_1_19_Version && handler.GetEntityHandlingEnabled()) throw new NotImplementedException(Translations.Get("exception.palette.entity")); - if (protocolversion >= MC_1_17_Version) + + if (protocolVersion == MC_1_19_Version) + entityPalette = new EntityPalette119(); + else if (protocolVersion >= MC_1_17_Version) entityPalette = new EntityPalette117(); - else if (protocolversion >= MC_1_16_2_Version) - if (protocolversion >= MC_1_16_2_Version) - entityPalette = new EntityPalette1162(); - else if (protocolversion >= MC_1_16_Version) - entityPalette = new EntityPalette1161(); - else if (protocolversion >= MC_1_15_Version) - entityPalette = new EntityPalette115(); - else if (protocolVersion >= MC_1_14_Version) - entityPalette = new EntityPalette114(); - else entityPalette = new EntityPalette113(); + else if (protocolVersion >= MC_1_16_2_Version) + entityPalette = new EntityPalette1162(); + else if (protocolVersion >= MC_1_16_Version) + entityPalette = new EntityPalette1161(); + else if (protocolVersion >= MC_1_15_Version) + entityPalette = new EntityPalette115(); + else if (protocolVersion >= MC_1_14_Version) + entityPalette = new EntityPalette114(); + else entityPalette = new EntityPalette113(); } else entityPalette = new EntityPalette112(); // Item palette - if (protocolversion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) { - if (protocolversion > MC_1_18_2_Version && handler.GetInventoryEnabled()) + if (protocolVersion > MC_1_19_Version && handler.GetInventoryEnabled()) throw new NotImplementedException(Translations.Get("exception.palette.item")); - if (protocolversion >= MC_1_18_1_Version) + + if (protocolVersion == MC_1_19_Version) + itemPalette = new ItemPalette119(); + else if (protocolVersion >= MC_1_18_1_Version) itemPalette = new ItemPalette118(); - else if (protocolversion >= MC_1_17_Version) + else if (protocolVersion >= MC_1_17_Version) itemPalette = new ItemPalette117(); - else if (protocolversion >= MC_1_16_2_Version) - if (protocolversion >= MC_1_16_2_Version) + else if (protocolVersion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) itemPalette = new ItemPalette1162(); else itemPalette = new ItemPalette1161(); } @@ -244,7 +252,7 @@ namespace MinecraftClient.Protocol.Handlers packetData.Enqueue(rawpacket[i]); //Handle packet decompression - if (protocolversion >= MC_1_8_Version + if (protocolVersion >= MC_1_8_Version && compression_treshold > 0) { int sizeUncompressed = dataTypes.ReadNextVarInt(packetData); @@ -282,7 +290,7 @@ namespace MinecraftClient.Protocol.Handlers switch (packetID) //Packet IDs are different while logging in { case 0x03: - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) compression_treshold = dataTypes.ReadNextVarInt(packetData); break; case 0x04: @@ -309,12 +317,12 @@ namespace MinecraftClient.Protocol.Handlers int playerEntityID = dataTypes.ReadNextInt(packetData); handler.OnReceivePlayerEntityID(playerEntityID); - if (protocolversion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) dataTypes.ReadNextBool(packetData); // Is hardcore - 1.16.2 and above handler.OnGamemodeUpdate(Guid.Empty, dataTypes.ReadNextByte(packetData)); - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) { dataTypes.ReadNextByte(packetData); // Previous Gamemode - 1.16 and above int worldCount = dataTypes.ReadNextVarInt(packetData); // Dimension Count (World Count) - 1.16 and above @@ -331,55 +339,55 @@ namespace MinecraftClient.Protocol.Handlers // String identifier: 1.16 and 1.16.1 // varInt: [1.9.1 to 1.15.2] // byte: below 1.9.1 - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) { - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) { dataTypes.ReadNextString(packetData); // Dimension Type: Identifier currentDimensionType = new Dictionary(); } - else if (protocolversion >= MC_1_16_2_Version) + else if (protocolVersion >= MC_1_16_2_Version) currentDimensionType = dataTypes.ReadNextNbt(packetData); // Dimension Type: NBT Tag Compound else dataTypes.ReadNextString(packetData); this.currentDimension = 0; } - else if (protocolversion >= MC_1_9_1_Version) + else if (protocolVersion >= MC_1_9_1_Version) this.currentDimension = dataTypes.ReadNextInt(packetData); else this.currentDimension = (sbyte)dataTypes.ReadNextByte(packetData); - if (protocolversion < MC_1_14_Version) + if (protocolVersion < MC_1_14_Version) dataTypes.ReadNextByte(packetData); // Difficulty - 1.13 and below - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) currentDimensionName = dataTypes.ReadNextString(packetData); // Dimension Name (World Name) - 1.16 and above - if (protocolversion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) World.SetDimension(currentDimensionName, currentDimensionType); - if (protocolversion >= MC_1_15_Version) + if (protocolVersion >= MC_1_15_Version) dataTypes.ReadNextLong(packetData); // Hashed world seed - 1.15 and above - if (protocolversion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) dataTypes.ReadNextVarInt(packetData); // Max Players - 1.16.2 and above else dataTypes.ReadNextByte(packetData); // Max Players - 1.16.1 and below - if (protocolversion < MC_1_16_Version) + if (protocolVersion < MC_1_16_Version) dataTypes.ReadNextString(packetData); // Level Type - 1.15 and below - if (protocolversion >= MC_1_14_Version) + if (protocolVersion >= MC_1_14_Version) dataTypes.ReadNextVarInt(packetData); // View distance - 1.14 and above - if (protocolversion >= MC_1_18_1_Version) + if (protocolVersion >= MC_1_18_1_Version) dataTypes.ReadNextVarInt(packetData); // Simulation Distance - 1.18 and above - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) dataTypes.ReadNextBool(packetData); // Reduced debug info - 1.8 and above - if (protocolversion >= MC_1_15_Version) + if (protocolVersion >= MC_1_15_Version) dataTypes.ReadNextBool(packetData); // Enable respawn screen - 1.15 and above - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) { dataTypes.ReadNextBool(packetData); // Is Debug - 1.16 and above dataTypes.ReadNextBool(packetData); // Is Flat - 1.16 and above } - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) { bool hasDeathLocation = dataTypes.ReadNextBool(packetData); // Has death location if (hasDeathLocation) @@ -392,12 +400,12 @@ namespace MinecraftClient.Protocol.Handlers case PacketTypesIn.ChatMessage: int messageType = 0; - if (protocolversion <= MC_1_18_2_Version) // 1.18 and bellow + if (protocolVersion <= MC_1_18_2_Version) // 1.18 and bellow { string message = dataTypes.ReadNextString(packetData); Guid senderUUID; - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) { //Hide system messages or xp bar messages? messageType = dataTypes.ReadNextByte(packetData); @@ -405,7 +413,7 @@ namespace MinecraftClient.Protocol.Handlers || (messageType == 2 && !Settings.DisplayXPBarMessages)) break; - if (protocolversion >= MC_1_16_5_Version) + if (protocolVersion >= MC_1_16_5_Version) senderUUID = dataTypes.ReadNextUUID(packetData); else senderUUID = Guid.Empty; } @@ -447,14 +455,14 @@ namespace MinecraftClient.Protocol.Handlers case PacketTypesIn.Respawn: string? dimensionNameInRespawn = null; Dictionary dimensionTypeInRespawn = null; - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) { - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) { dataTypes.ReadNextString(packetData); // Dimension Type: Identifier dimensionTypeInRespawn = new Dictionary(); } - else if (protocolversion >= MC_1_16_2_Version) + else if (protocolVersion >= MC_1_16_2_Version) dimensionTypeInRespawn = dataTypes.ReadNextNbt(packetData); // Dimension Type: NBT Tag Compound else dataTypes.ReadNextString(packetData); @@ -465,28 +473,28 @@ namespace MinecraftClient.Protocol.Handlers // 1.15 and below this.currentDimension = dataTypes.ReadNextInt(packetData); } - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) dimensionNameInRespawn = dataTypes.ReadNextString(packetData); // Dimension Name (World Name) - 1.16 and above - if (protocolversion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) World.SetDimension(dimensionNameInRespawn, dimensionTypeInRespawn); - if (protocolversion < MC_1_14_Version) + if (protocolVersion < MC_1_14_Version) dataTypes.ReadNextByte(packetData); // Difficulty - 1.13 and below - if (protocolversion >= MC_1_15_Version) + if (protocolVersion >= MC_1_15_Version) dataTypes.ReadNextLong(packetData); // Hashed world seed - 1.15 and above dataTypes.ReadNextByte(packetData); // Gamemode - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) dataTypes.ReadNextByte(packetData); // Previous Game mode - 1.16 and above - if (protocolversion < MC_1_16_Version) + if (protocolVersion < MC_1_16_Version) dataTypes.ReadNextString(packetData); // Level Type - 1.15 and below - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) { dataTypes.ReadNextBool(packetData); // Is Debug - 1.16 and above dataTypes.ReadNextBool(packetData); // Is Flat - 1.16 and above dataTypes.ReadNextBool(packetData); // Copy metadata - 1.16 and above } - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) { bool hasDeathLocation = dataTypes.ReadNextBool(packetData); // Has death location if (hasDeathLocation) @@ -509,7 +517,7 @@ namespace MinecraftClient.Protocol.Handlers // entity handling require player pos for distance calculating if (handler.GetTerrainEnabled() || handler.GetEntityHandlingEnabled()) { - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) { Location location = handler.GetCurrentLocation(); location.X = (locMask & 1 << 0) != 0 ? location.X + x : x; @@ -520,14 +528,14 @@ namespace MinecraftClient.Protocol.Handlers else handler.UpdateLocation(new Location(x, y, z), yaw, pitch); } - if (protocolversion >= MC_1_9_Version) + if (protocolVersion >= MC_1_9_Version) { int teleportID = dataTypes.ReadNextVarInt(packetData); // Teleport confirm packet SendPacket(PacketTypesOut.TeleportConfirm, dataTypes.GetVarInt(teleportID)); } - if (protocolversion >= MC_1_17_Version) + if (protocolVersion >= MC_1_17_Version) dataTypes.ReadNextBool(packetData); // Dismount Vehicle - 1.17 and above break; case PacketTypesIn.ChunkData: @@ -535,16 +543,16 @@ namespace MinecraftClient.Protocol.Handlers { int chunkX = dataTypes.ReadNextInt(packetData); int chunkZ = dataTypes.ReadNextInt(packetData); - if (protocolversion >= MC_1_17_Version) + if (protocolVersion >= MC_1_17_Version) { ulong[]? verticalStripBitmask = null; - if (protocolversion == MC_1_17_Version || protocolversion == MC_1_17_1_Version) + if (protocolVersion == MC_1_17_Version || protocolVersion == MC_1_17_1_Version) verticalStripBitmask = dataTypes.ReadNextULongArray(packetData); // Bit Mask Le:ngth and Primary Bit Mask dataTypes.ReadNextNbt(packetData); // Heightmaps - if (protocolversion == MC_1_17_Version || protocolversion == MC_1_17_1_Version) + if (protocolVersion == MC_1_17_Version || protocolVersion == MC_1_17_1_Version) { int biomesLength = dataTypes.ReadNextVarInt(packetData); // Biomes length for (int i = 0; i < biomesLength; i++) @@ -566,12 +574,12 @@ namespace MinecraftClient.Protocol.Handlers else { bool chunksContinuous = dataTypes.ReadNextBool(packetData); - if (protocolversion >= MC_1_16_Version && protocolversion <= MC_1_16_1_Version) + if (protocolVersion >= MC_1_16_Version && protocolVersion <= MC_1_16_1_Version) dataTypes.ReadNextBool(packetData); // Ignore old data - 1.16 to 1.16.1 only - ushort chunkMask = protocolversion >= MC_1_9_Version + ushort chunkMask = protocolVersion >= MC_1_9_Version ? (ushort)dataTypes.ReadNextVarInt(packetData) : dataTypes.ReadNextUShort(packetData); - if (protocolversion < MC_1_8_Version) + if (protocolVersion < MC_1_8_Version) { ushort addBitmap = dataTypes.ReadNextUShort(packetData); int compressedDataSize = dataTypes.ReadNextInt(packetData); @@ -584,15 +592,15 @@ namespace MinecraftClient.Protocol.Handlers } else { - if (protocolversion >= MC_1_14_Version) + if (protocolVersion >= MC_1_14_Version) dataTypes.ReadNextNbt(packetData); // Heightmaps - 1.14 and above int biomesLength = 0; - if (protocolversion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) if (chunksContinuous) biomesLength = dataTypes.ReadNextVarInt(packetData); // Biomes length - 1.16.2 and above - if (protocolversion >= MC_1_15_Version && chunksContinuous) + if (protocolVersion >= MC_1_15_Version && chunksContinuous) { - if (protocolversion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) { for (int i = 0; i < biomesLength; i++) { @@ -615,13 +623,13 @@ namespace MinecraftClient.Protocol.Handlers case PacketTypesIn.MapData: int mapid = dataTypes.ReadNextVarInt(packetData); byte scale = dataTypes.ReadNextByte(packetData); - bool trackingposition = protocolversion >= MC_1_17_Version ? false : dataTypes.ReadNextBool(packetData); + bool trackingposition = protocolVersion >= MC_1_17_Version ? false : dataTypes.ReadNextBool(packetData); bool locked = false; - if (protocolversion >= MC_1_14_Version) + if (protocolVersion >= MC_1_14_Version) { locked = dataTypes.ReadNextBool(packetData); } - if (protocolversion >= MC_1_17_Version) + if (protocolVersion >= MC_1_17_Version) { trackingposition = dataTypes.ReadNextBool(packetData); } @@ -629,7 +637,7 @@ namespace MinecraftClient.Protocol.Handlers handler.OnMapData(mapid, scale, trackingposition, locked, iconcount); break; case PacketTypesIn.TradeList: - if ((protocolversion >= MC_1_14_Version) && (handler.GetInventoryEnabled())) + if ((protocolVersion >= MC_1_14_Version) && (handler.GetInventoryEnabled())) { // MC 1.14 or greater int windowID = dataTypes.ReadNextVarInt(packetData); @@ -651,7 +659,7 @@ namespace MinecraftClient.Protocol.Handlers } break; case PacketTypesIn.Title: - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) { int action2 = dataTypes.ReadNextVarInt(packetData); string titletext = String.Empty; @@ -661,7 +669,7 @@ namespace MinecraftClient.Protocol.Handlers int fadein = -1; int stay = -1; int fadeout = -1; - if (protocolversion >= MC_1_10_Version) + if (protocolVersion >= MC_1_10_Version) { if (action2 == 0) { @@ -710,7 +718,7 @@ namespace MinecraftClient.Protocol.Handlers case PacketTypesIn.MultiBlockChange: if (handler.GetTerrainEnabled()) { - if (protocolversion >= MC_1_16_2_Version) + if (protocolVersion >= MC_1_16_2_Version) { long chunkSection = dataTypes.ReadNextLong(packetData); int sectionX = (int)(chunkSection >> 42); @@ -738,7 +746,7 @@ namespace MinecraftClient.Protocol.Handlers { int chunkX = dataTypes.ReadNextInt(packetData); int chunkZ = dataTypes.ReadNextInt(packetData); - int recordCount = protocolversion < MC_1_8_Version + int recordCount = protocolVersion < MC_1_8_Version ? (int)dataTypes.ReadNextShort(packetData) : dataTypes.ReadNextVarInt(packetData); @@ -748,7 +756,7 @@ namespace MinecraftClient.Protocol.Handlers ushort blockIdMeta; int blockY; - if (protocolversion < MC_1_8_Version) + if (protocolVersion < MC_1_8_Version) { blockIdMeta = dataTypes.ReadNextUShort(packetData); blockY = (ushort)dataTypes.ReadNextByte(packetData); @@ -787,7 +795,7 @@ namespace MinecraftClient.Protocol.Handlers case PacketTypesIn.BlockChange: if (handler.GetTerrainEnabled()) { - if (protocolversion < MC_1_8_Version) + if (protocolVersion < MC_1_8_Version) { int blockX = dataTypes.ReadNextInt(packetData); int blockY = dataTypes.ReadNextByte(packetData); @@ -798,7 +806,12 @@ namespace MinecraftClient.Protocol.Handlers } else { - handler.GetWorld().SetBlock(dataTypes.ReadNextLocation(packetData), new Block((ushort)dataTypes.ReadNextVarInt(packetData))); + if (protocolVersion < MC_1_19_Version) + handler.GetWorld().SetBlock(dataTypes.ReadNextLocation(packetData), new Block((ushort)dataTypes.ReadNextVarInt(packetData))); + else + { + // 1.19 disabled due to crashing + } } } break; @@ -823,14 +836,14 @@ namespace MinecraftClient.Protocol.Handlers break; case PacketTypesIn.MapChunkBulk: - if (protocolversion < MC_1_9_Version && handler.GetTerrainEnabled()) + if (protocolVersion < MC_1_9_Version && handler.GetTerrainEnabled()) { int chunkCount; bool hasSkyLight; Queue chunkData = packetData; //Read global fields - if (protocolversion < MC_1_8_Version) + if (protocolVersion < MC_1_8_Version) { chunkCount = dataTypes.ReadNextShort(packetData); int compressedDataSize = dataTypes.ReadNextInt(packetData); @@ -855,7 +868,7 @@ namespace MinecraftClient.Protocol.Handlers chunkXs[chunkColumnNo] = dataTypes.ReadNextInt(packetData); chunkZs[chunkColumnNo] = dataTypes.ReadNextInt(packetData); chunkMasks[chunkColumnNo] = dataTypes.ReadNextUShort(packetData); - addBitmaps[chunkColumnNo] = protocolversion < MC_1_8_Version + addBitmaps[chunkColumnNo] = protocolVersion < MC_1_8_Version ? dataTypes.ReadNextUShort(packetData) : (ushort)0; } @@ -866,7 +879,7 @@ namespace MinecraftClient.Protocol.Handlers } break; case PacketTypesIn.UnloadChunk: - if (protocolversion >= MC_1_9_Version && handler.GetTerrainEnabled()) + if (protocolVersion >= MC_1_9_Version && handler.GetTerrainEnabled()) { int chunkX = dataTypes.ReadNextInt(packetData); int chunkZ = dataTypes.ReadNextInt(packetData); @@ -881,7 +894,7 @@ namespace MinecraftClient.Protocol.Handlers } break; case PacketTypesIn.PlayerInfo: - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) { int action = dataTypes.ReadNextVarInt(packetData); // Action Name int numberOfPlayers = dataTypes.ReadNextVarInt(packetData); // Number Of Players @@ -918,7 +931,7 @@ namespace MinecraftClient.Protocol.Handlers // 1.19 Additions long? keyExpiration = null; byte[]? publicKey = null, signature = null; - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) { if (dataTypes.ReadNextBool(packetData)) // Has Sig Data (if true, red the following fields) { @@ -968,7 +981,7 @@ namespace MinecraftClient.Protocol.Handlers } break; case PacketTypesIn.TabComplete: - if (protocolversion >= MC_1_13_Version) + if (protocolVersion >= MC_1_13_Version) { autocomplete_transaction_id = dataTypes.ReadNextVarInt(packetData); dataTypes.ReadNextVarInt(packetData); // Start of text to replace @@ -981,7 +994,7 @@ namespace MinecraftClient.Protocol.Handlers for (int i = 0; i < autocomplete_count; i++) { autocomplete_result.Add(dataTypes.ReadNextString(packetData)); - if (protocolversion >= MC_1_13_Version) + if (protocolVersion >= MC_1_13_Version) { // Skip optional tooltip for each tab-complete result if (dataTypes.ReadNextBool(packetData)) @@ -994,7 +1007,7 @@ namespace MinecraftClient.Protocol.Handlers case PacketTypesIn.PluginMessage: String channel = dataTypes.ReadNextString(packetData); // Length is unneeded as the whole remaining packetData is the entire payload of the packet. - if (protocolversion < MC_1_8_Version) + if (protocolVersion < MC_1_8_Version) pForge.ReadNextVarShort(packetData); handler.OnPluginChannelMessage(channel, packetData.ToArray()); return pForge.HandlePluginMessage(channel, packetData, ref currentDimension); @@ -1002,13 +1015,13 @@ namespace MinecraftClient.Protocol.Handlers handler.OnConnectionLost(ChatBot.DisconnectReason.InGameKick, ChatParser.ParseText(dataTypes.ReadNextString(packetData))); return false; case PacketTypesIn.SetCompression: - if (protocolversion >= MC_1_8_Version && protocolversion < MC_1_9_Version) + if (protocolVersion >= MC_1_8_Version && protocolVersion < MC_1_9_Version) compression_treshold = dataTypes.ReadNextVarInt(packetData); break; case PacketTypesIn.OpenWindow: if (handler.GetInventoryEnabled()) { - if (protocolversion < MC_1_14_Version) + if (protocolVersion < MC_1_14_Version) { // MC 1.13 or lower byte windowID = dataTypes.ReadNextByte(packetData); @@ -1045,7 +1058,7 @@ namespace MinecraftClient.Protocol.Handlers int stateId = -1; int elements = 0; - if (protocolversion >= MC_1_17_1_Version) + if (protocolVersion >= MC_1_17_1_Version) { // State ID and Elements as VarInt - 1.17.1 and above stateId = dataTypes.ReadNextVarInt(packetData); @@ -1065,7 +1078,7 @@ namespace MinecraftClient.Protocol.Handlers inventorySlots[slotId] = item; } - if (protocolversion >= MC_1_17_1_Version) // Carried Item - 1.17.1 and above + if (protocolVersion >= MC_1_17_1_Version) // Carried Item - 1.17.1 and above dataTypes.ReadNextItemSlot(packetData, itemPalette); handler.OnWindowItems(windowId, inventorySlots, stateId); @@ -1076,7 +1089,7 @@ namespace MinecraftClient.Protocol.Handlers { byte windowID = dataTypes.ReadNextByte(packetData); int stateId = -1; - if (protocolversion >= MC_1_17_1_Version) + if (protocolVersion >= MC_1_17_1_Version) stateId = dataTypes.ReadNextVarInt(packetData); // State ID - 1.17.1 and above short slotID = dataTypes.ReadNextShort(packetData); Item item = dataTypes.ReadNextItemSlot(packetData, itemPalette); @@ -1099,7 +1112,7 @@ namespace MinecraftClient.Protocol.Handlers string url = dataTypes.ReadNextString(packetData); string hash = dataTypes.ReadNextString(packetData); bool forced = true; // Assume forced for MC 1.16 and below - if (protocolversion >= MC_1_17_Version) + if (protocolVersion >= MC_1_17_Version) { forced = dataTypes.ReadNextBool(packetData); string forcedMessage = ChatParser.ParseText(dataTypes.ReadNextString(packetData)); @@ -1111,7 +1124,7 @@ namespace MinecraftClient.Protocol.Handlers break; //Send back "accepted" and "successfully loaded" responses for plugins or server config making use of resource pack mandatory byte[] responseHeader = new byte[0]; - if (protocolversion < MC_1_10_Version) //MC 1.10 does not include resource pack hash in responses + if (protocolVersion < MC_1_10_Version) //MC 1.10 does not include resource pack hash in responses responseHeader = dataTypes.ConcatBytes(dataTypes.GetVarInt(hash.Length), Encoding.UTF8.GetBytes(hash)); SendPacket(PacketTypesOut.ResourcePackStatus, dataTypes.ConcatBytes(responseHeader, dataTypes.GetVarInt(3))); //Accepted pack SendPacket(PacketTypesOut.ResourcePackStatus, dataTypes.ConcatBytes(responseHeader, dataTypes.GetVarInt(0))); //Successfully loaded @@ -1127,7 +1140,7 @@ namespace MinecraftClient.Protocol.Handlers if (handler.GetEntityHandlingEnabled()) { int entityid = dataTypes.ReadNextVarInt(packetData); - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) { bool hasNext; do @@ -1188,7 +1201,7 @@ namespace MinecraftClient.Protocol.Handlers bool hasFactorData = false; Dictionary? factorCodec = null; - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) { hasFactorData = dataTypes.ReadNextBool(packetData); factorCodec = dataTypes.ReadNextNbt(packetData); @@ -1202,7 +1215,7 @@ namespace MinecraftClient.Protocol.Handlers if (handler.GetEntityHandlingEnabled()) { int entityCount = 1; // 1.17.0 has only one entity per packet - if (protocolversion != MC_1_17_Version) + if (protocolVersion != MC_1_17_Version) entityCount = dataTypes.ReadNextVarInt(packetData); // All other versions have a "count" field int[] entityList = new int[entityCount]; for (int i = 0; i < entityCount; i++) @@ -1246,7 +1259,7 @@ namespace MinecraftClient.Protocol.Handlers if (handler.GetEntityHandlingEnabled()) { int EntityID = dataTypes.ReadNextVarInt(packetData); - int NumberOfProperties = protocolversion >= MC_1_17_Version ? dataTypes.ReadNextVarInt(packetData) : dataTypes.ReadNextInt(packetData); + int NumberOfProperties = protocolVersion >= MC_1_17_Version ? dataTypes.ReadNextVarInt(packetData) : dataTypes.ReadNextInt(packetData); Dictionary keys = new Dictionary(); for (int i = 0; i < NumberOfProperties; i++) { @@ -1285,11 +1298,11 @@ namespace MinecraftClient.Protocol.Handlers // See https://wiki.vg/Entity_metadata#Living_Entity int healthField = 7; // From 1.10 to 1.13.2 - if (protocolversion >= MC_1_14_Version) + if (protocolVersion >= MC_1_14_Version) healthField = 8; // 1.14 and above - if (protocolversion >= MC_1_17_Version) + if (protocolVersion >= MC_1_17_Version) healthField = 9; // 1.17 and above - if (protocolversion > MC_1_18_2_Version) + if (protocolVersion > MC_1_19_Version) throw new NotImplementedException(Translations.Get("exception.palette.healthfield")); if (metadata.ContainsKey(healthField) && metadata[healthField] != null && metadata[healthField].GetType() == typeof(float)) @@ -1333,7 +1346,7 @@ namespace MinecraftClient.Protocol.Handlers case PacketTypesIn.UpdateHealth: float health = dataTypes.ReadNextFloat(packetData); int food; - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) food = dataTypes.ReadNextVarInt(packetData); else food = dataTypes.ReadNextShort(packetData); @@ -1348,12 +1361,12 @@ namespace MinecraftClient.Protocol.Handlers break; case PacketTypesIn.Explosion: Location explosionLocation; - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) explosionLocation = new(dataTypes.ReadNextDouble(packetData), dataTypes.ReadNextDouble(packetData), dataTypes.ReadNextDouble(packetData)); else explosionLocation = new(dataTypes.ReadNextFloat(packetData), dataTypes.ReadNextFloat(packetData), dataTypes.ReadNextFloat(packetData)); float explosionStrength = dataTypes.ReadNextFloat(packetData); - int explosionBlockCount = protocolversion >= MC_1_17_Version + int explosionBlockCount = protocolVersion >= MC_1_17_Version ? dataTypes.ReadNextVarInt(packetData) : dataTypes.ReadNextInt(packetData); // Ignoring additional fields (records, pushback) @@ -1377,12 +1390,12 @@ namespace MinecraftClient.Protocol.Handlers break; case PacketTypesIn.UpdateScore: string entityname = dataTypes.ReadNextString(packetData); - int action3 = protocolversion >= MC_1_18_2_Version + int action3 = protocolVersion >= MC_1_18_2_Version ? dataTypes.ReadNextVarInt(packetData) : dataTypes.ReadNextByte(packetData); string objectivename2 = string.Empty; int value = -1; - if (action3 != 1 || protocolversion >= MC_1_8_Version) + if (action3 != 1 || protocolVersion >= MC_1_8_Version) objectivename2 = dataTypes.ReadNextString(packetData); if (action3 != 1) value = dataTypes.ReadNextVarInt(packetData); @@ -1421,7 +1434,7 @@ namespace MinecraftClient.Protocol.Handlers Translations.Get("exception.packet_process", packetPalette.GetIncommingTypeById(packetID), packetID, - protocolversion, + protocolVersion, login_phase, innerException.GetType()), innerException); @@ -1515,7 +1528,7 @@ namespace MinecraftClient.Protocol.Handlers /// True if login successful public bool Login(PlayerKeyPair? playerKeyPair) { - byte[] protocol_version = dataTypes.GetVarInt(protocolversion); + byte[] protocol_version = dataTypes.GetVarInt(protocolVersion); string server_address = pForge.GetServerAddress(handler.GetServerHost()); byte[] server_port = dataTypes.GetUShort((ushort)handler.GetServerPort()); byte[] next_state = dataTypes.GetVarInt(2); @@ -1524,7 +1537,7 @@ namespace MinecraftClient.Protocol.Handlers List fullLoginPacket = new List(); fullLoginPacket.AddRange(dataTypes.GetString(handler.GetUsername())); // Username - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) { if (playerKeyPair == null) fullLoginPacket.AddRange(dataTypes.GetBool(false)); // Has Sig Data @@ -1598,7 +1611,7 @@ namespace MinecraftClient.Protocol.Handlers // Encryption Response packet List encryptionResponse = new(); encryptionResponse.AddRange(dataTypes.GetArray(RSAService.Encrypt(secretKey, false))); // Shared Secret - if (protocolversion >= Protocol18Handler.MC_1_19_Version) + if (protocolVersion >= Protocol18Handler.MC_1_19_Version) { if (playerKeyPair == null) { @@ -1646,7 +1659,7 @@ namespace MinecraftClient.Protocol.Handlers Guid uuidReceived = dataTypes.ReadNextUUID(packetData); string userName = dataTypes.ReadNextString(packetData); Tuple[]? playerProperty = null; - if (protocolversion >= Protocol18Handler.MC_1_19_Version) + if (protocolVersion >= Protocol18Handler.MC_1_19_Version) { int count = dataTypes.ReadNextVarInt(packetData); // Number Of Properties playerProperty = new Tuple[count]; @@ -1701,9 +1714,9 @@ namespace MinecraftClient.Protocol.Handlers byte[] tabcomplete_packet = new byte[] { }; - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) { - if (protocolversion >= MC_1_13_Version) + if (protocolVersion >= MC_1_13_Version) { tabcomplete_packet = dataTypes.ConcatBytes(tabcomplete_packet, transaction_id); tabcomplete_packet = dataTypes.ConcatBytes(tabcomplete_packet, dataTypes.GetString(BehindCursor)); @@ -1712,7 +1725,7 @@ namespace MinecraftClient.Protocol.Handlers { tabcomplete_packet = dataTypes.ConcatBytes(tabcomplete_packet, dataTypes.GetString(BehindCursor)); - if (protocolversion >= MC_1_9_Version) + if (protocolVersion >= MC_1_9_Version) { tabcomplete_packet = dataTypes.ConcatBytes(tabcomplete_packet, assume_command); } @@ -1745,7 +1758,7 @@ namespace MinecraftClient.Protocol.Handlers /// Ping a Minecraft server to get information about the server /// /// True if ping was successful - public static bool doPing(string host, int port, ref int protocolversion, ref ForgeInfo? forgeInfo) + public static bool doPing(string host, int port, ref int protocolVersion, ref ForgeInfo? forgeInfo) { string version = ""; TcpClient tcp = ProxyHandler.newTcpClient(host, port); @@ -1797,12 +1810,12 @@ namespace MinecraftClient.Protocol.Handlers //Retrieve protocol version number for handling this server if (versionData.Properties.ContainsKey("protocol")) - protocolversion = int.Parse(versionData.Properties["protocol"].StringValue); + protocolVersion = int.Parse(versionData.Properties["protocol"].StringValue); // Check for forge on the server. Protocol18Forge.ServerInfoCheckForge(jsonData, ref forgeInfo); - ConsoleIO.WriteLineFormatted(Translations.Get("mcc.server_protocol", version, protocolversion + (forgeInfo != null ? Translations.Get("mcc.with_forge") : ""))); + ConsoleIO.WriteLineFormatted(Translations.Get("mcc.server_protocol", version, protocolVersion + (forgeInfo != null ? Translations.Get("mcc.with_forge") : ""))); return true; } @@ -1818,7 +1831,7 @@ namespace MinecraftClient.Protocol.Handlers /// Max length, in characters public int GetMaxChatMessageLength() { - return protocolversion > MC_1_10_Version + return protocolVersion > MC_1_10_Version ? 256 : 100; } @@ -1832,7 +1845,7 @@ namespace MinecraftClient.Protocol.Handlers /// Minecraft Protocol version number public int GetProtocolVersion() { - return protocolversion; + return protocolVersion; } @@ -1953,7 +1966,7 @@ namespace MinecraftClient.Protocol.Handlers return true; // Process Chat Command - 1.19 and above - if (protocolversion >= MC_1_19_Version && message.StartsWith('/')) + if (protocolVersion >= MC_1_19_Version && message.StartsWith('/')) return SendChatCommand(message[1..], playerKeyPair); try @@ -1963,7 +1976,7 @@ namespace MinecraftClient.Protocol.Handlers // Message: String (up to 256 chars) fields.AddRange(dataTypes.GetString(message)); - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) { // Timestamp: Instant(Long) DateTimeOffset timeNow = DateTimeOffset.UtcNow; @@ -2041,7 +2054,7 @@ namespace MinecraftClient.Protocol.Handlers return false; // Plugin channels were significantly changed between Minecraft 1.12 and 1.13 // https://wiki.vg/index.php?title=Pre-release_protocol&oldid=14132#Plugin_Channels - if (protocolversion >= MC_1_13_Version) + if (protocolVersion >= MC_1_13_Version) { return SendPluginChannelPacket("minecraft:brand", dataTypes.GetString(brandInfo)); } @@ -2069,26 +2082,26 @@ namespace MinecraftClient.Protocol.Handlers List fields = new List(); fields.AddRange(dataTypes.GetString(language)); fields.Add(viewDistance); - fields.AddRange(protocolversion >= MC_1_9_Version + fields.AddRange(protocolVersion >= MC_1_9_Version ? dataTypes.GetVarInt(chatMode) : new byte[] { chatMode }); fields.Add(chatColors ? (byte)1 : (byte)0); - if (protocolversion < MC_1_8_Version) + if (protocolVersion < MC_1_8_Version) { fields.Add(difficulty); fields.Add((byte)(skinParts & 0x1)); //show cape } else fields.Add(skinParts); - if (protocolversion >= MC_1_9_Version) + if (protocolVersion >= MC_1_9_Version) fields.AddRange(dataTypes.GetVarInt(mainHand)); - if (protocolversion >= MC_1_17_Version) + if (protocolVersion >= MC_1_17_Version) { - if (protocolversion >= MC_1_18_1_Version) + if (protocolVersion >= MC_1_18_1_Version) fields.Add(0); // 1.18 and above - Enable text filtering. (Always false) else fields.Add(1); // 1.17 and 1.17.1 - Disable text filtering. (Always true) } - if (protocolversion >= MC_1_18_1_Version) + if (protocolVersion >= MC_1_18_1_Version) fields.Add(1); // 1.18 and above - Allow server listings SendPacket(PacketTypesOut.ClientSettings, fields); } @@ -2124,7 +2137,7 @@ namespace MinecraftClient.Protocol.Handlers SendPacket(packetType, dataTypes.ConcatBytes( dataTypes.GetDouble(location.X), dataTypes.GetDouble(location.Y), - protocolversion < MC_1_8_Version + protocolVersion < MC_1_8_Version ? dataTypes.GetDouble(location.Y + 1.62) : new byte[0], dataTypes.GetDouble(location.Z), @@ -2150,7 +2163,7 @@ namespace MinecraftClient.Protocol.Handlers { // In 1.7, length needs to be included. // In 1.8, it must not be. - if (protocolversion < MC_1_8_Version) + if (protocolVersion < MC_1_8_Version) { byte[] length = BitConverter.GetBytes((short)data.Length); Array.Reverse(length); @@ -2205,7 +2218,7 @@ namespace MinecraftClient.Protocol.Handlers // Is player Sneaking (Only 1.16 and above) // Currently hardcoded to false // TODO: Update to reflect the real player state - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) fields.AddRange(dataTypes.GetBool(false)); SendPacket(PacketTypesOut.InteractEntity, fields); @@ -2231,7 +2244,7 @@ namespace MinecraftClient.Protocol.Handlers // Is player Sneaking (Only 1.16 and above) // Currently hardcoded to false // TODO: Update to reflect the real player state - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) fields.AddRange(dataTypes.GetBool(false)); SendPacket(PacketTypesOut.InteractEntity, fields); return true; @@ -2251,7 +2264,7 @@ namespace MinecraftClient.Protocol.Handlers // Is player Sneaking (Only 1.16 and above) // Currently hardcoded to false // TODO: Update to reflect the real player state - if (protocolversion >= MC_1_16_Version) + if (protocolVersion >= MC_1_16_Version) fields.AddRange(dataTypes.GetBool(false)); SendPacket(PacketTypesOut.InteractEntity, fields); return true; @@ -2267,7 +2280,7 @@ namespace MinecraftClient.Protocol.Handlers public bool SendUseItem(int hand, int sequenceId) { - if (protocolversion < MC_1_9_Version) + if (protocolVersion < MC_1_9_Version) return false; // Packet does not exist prior to MC 1.9 // According to https://wiki.vg/index.php?title=Protocol&oldid=5486#Player_Block_Placement // MC 1.7 does this using Player Block Placement with special values @@ -2276,7 +2289,7 @@ namespace MinecraftClient.Protocol.Handlers { List packet = new List(); packet.AddRange(dataTypes.GetVarInt(hand)); - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) packet.AddRange(dataTypes.GetVarInt(sequenceId)); SendPacket(PacketTypesOut.UseItem, packet); return true; @@ -2294,7 +2307,7 @@ namespace MinecraftClient.Protocol.Handlers packet.AddRange(dataTypes.GetVarInt(status)); packet.AddRange(dataTypes.GetLocation(location)); packet.AddRange(dataTypes.GetVarInt(dataTypes.GetBlockFace(face))); - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) packet.AddRange(dataTypes.GetVarInt(sequenceId)); SendPacket(PacketTypesOut.PlayerDigging, packet); return true; @@ -2306,7 +2319,7 @@ namespace MinecraftClient.Protocol.Handlers public bool SendPlayerBlockPlacement(int hand, Location location, Direction face, int sequenceId) { - if (protocolversion < MC_1_14_Version) + if (protocolVersion < MC_1_14_Version) return false; // NOT IMPLEMENTED for older MC versions try { @@ -2318,7 +2331,7 @@ namespace MinecraftClient.Protocol.Handlers packet.AddRange(dataTypes.GetFloat(0.5f)); // cursorY packet.AddRange(dataTypes.GetFloat(0.5f)); // cursorZ packet.Add(0); // insideBlock = false; - if (protocolversion >= MC_1_19_Version) + if (protocolVersion >= MC_1_19_Version) packet.AddRange(dataTypes.GetVarInt(sequenceId)); SendPacket(PacketTypesOut.PlayerBlockPlacement, packet); return true; @@ -2381,13 +2394,13 @@ namespace MinecraftClient.Protocol.Handlers packet.Add((byte)windowId); // Window ID // 1.18+ - if (protocolversion >= MC_1_18_1_Version) + if (protocolVersion >= MC_1_18_1_Version) { packet.AddRange(dataTypes.GetVarInt(stateId)); // State ID packet.AddRange(dataTypes.GetShort((short)slotId)); // Slot ID } // 1.17.1 - else if (protocolversion == MC_1_17_1_Version) + else if (protocolVersion == MC_1_17_1_Version) { packet.AddRange(dataTypes.GetShort((short)slotId)); // Slot ID packet.AddRange(dataTypes.GetVarInt(stateId)); // State ID @@ -2400,15 +2413,15 @@ namespace MinecraftClient.Protocol.Handlers packet.Add(button); // Button - if (protocolversion < MC_1_17_Version) + if (protocolVersion < MC_1_17_Version) packet.AddRange(dataTypes.GetShort(actionNumber)); - if (protocolversion >= MC_1_9_Version) + if (protocolVersion >= MC_1_9_Version) packet.AddRange(dataTypes.GetVarInt(mode)); // Mode else packet.Add(mode); // 1.17+ Array of changed slots - if (protocolversion >= MC_1_17_Version) + if (protocolVersion >= MC_1_17_Version) { packet.AddRange(dataTypes.GetVarInt(changedSlots.Count)); // Length of the array foreach (var slot in changedSlots) @@ -2451,12 +2464,12 @@ namespace MinecraftClient.Protocol.Handlers { List packet = new List(); - if (protocolversion < MC_1_8_Version) + if (protocolVersion < MC_1_8_Version) { packet.AddRange(dataTypes.GetInt(playerid)); packet.Add((byte)1); // Swing arm } - else if (protocolversion < MC_1_9_Version) + else if (protocolVersion < MC_1_9_Version) { // No fields in 1.8.X } @@ -2524,7 +2537,7 @@ namespace MinecraftClient.Protocol.Handlers public bool UpdateCommandBlock(Location location, string command, CommandBlockMode mode, CommandBlockFlags flags) { - if (protocolversion <= MC_1_13_Version) + if (protocolVersion <= MC_1_13_Version) { try { @@ -2562,7 +2575,7 @@ namespace MinecraftClient.Protocol.Handlers public bool SelectTrade(int selectedSlot) { // MC 1.13 or greater - if (protocolversion >= MC_1_13_Version) + if (protocolVersion >= MC_1_13_Version) { try { @@ -2581,7 +2594,7 @@ namespace MinecraftClient.Protocol.Handlers public bool SendSpectate(Guid UUID) { // MC 1.8 or greater - if (protocolversion >= MC_1_8_Version) + if (protocolVersion >= MC_1_8_Version) { try {