From f16e9e87dd82381514d5ea11300d88b4d47dfd25 Mon Sep 17 00:00:00 2001 From: ORelio Date: Sat, 29 May 2021 15:21:38 +0200 Subject: [PATCH] Add support for inventory layout as ASCII art (#906) Inventory art mostly made by Mhowser TODO: Implement remaining inventory types --- MinecraftClient/Commands/Inventory.cs | 3 + .../DefaultConfigResource.Designer.cs | 171 +++++++++++++++--- MinecraftClient/DefaultConfigResource.resx | 18 ++ .../Inventory/ContainerTypeExtensions.cs | 34 ++++ MinecraftClient/MinecraftClient.csproj | 6 + .../Resources/config/MinecraftClient.ini | 1 + .../containers/ContainerType.BrewingStand.txt | 22 +++ .../containers/ContainerType.Crafting.txt | 22 +++ .../containers/ContainerType.Generic_3x3.txt | 22 +++ .../containers/ContainerType.Generic_9x3.txt | 22 +++ .../containers/ContainerType.Generic_9x6.txt | 28 +++ .../ContainerType.PlayerInventory.txt | 22 +++ MinecraftClient/Settings.cs | 2 + 13 files changed, 351 insertions(+), 22 deletions(-) create mode 100644 MinecraftClient/Resources/containers/ContainerType.BrewingStand.txt create mode 100644 MinecraftClient/Resources/containers/ContainerType.Crafting.txt create mode 100644 MinecraftClient/Resources/containers/ContainerType.Generic_3x3.txt create mode 100644 MinecraftClient/Resources/containers/ContainerType.Generic_9x3.txt create mode 100644 MinecraftClient/Resources/containers/ContainerType.Generic_9x6.txt create mode 100644 MinecraftClient/Resources/containers/ContainerType.PlayerInventory.txt diff --git a/MinecraftClient/Commands/Inventory.cs b/MinecraftClient/Commands/Inventory.cs index 0340d837..7c3ff730 100644 --- a/MinecraftClient/Commands/Inventory.cs +++ b/MinecraftClient/Commands/Inventory.cs @@ -98,6 +98,9 @@ namespace MinecraftClient.Commands SortedDictionary itemsSorted = new SortedDictionary(inventory.Items); List response = new List(); response.Add(Translations.Get("cmd.inventory.inventory") + " #" + inventoryId + " - " + inventory.Title + "§8"); + string asciiArt = inventory.Type.GetAsciiArt(); + if (asciiArt != null && Settings.DisplayInventoryLayout) + response.Add(asciiArt); int selectedHotbar = handler.GetCurrentSlot() + 1; foreach (KeyValuePair item in itemsSorted) { diff --git a/MinecraftClient/DefaultConfigResource.Designer.cs b/MinecraftClient/DefaultConfigResource.Designer.cs index 6befa012..5c5c6e54 100644 --- a/MinecraftClient/DefaultConfigResource.Designer.cs +++ b/MinecraftClient/DefaultConfigResource.Designer.cs @@ -1,10 +1,10 @@ //------------------------------------------------------------------------------ // -// 這段程式碼是由工具產生的。 -// 執行階段版本:4.0.30319.42000 +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 // -// 對這個檔案所做的變更可能會造成錯誤的行為,而且如果重新產生程式碼, -// 變更將會遺失。 +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. // //------------------------------------------------------------------------------ @@ -13,13 +13,13 @@ namespace MinecraftClient { /// - /// 用於查詢當地語系化字串等的強類型資源類別。 + /// A strongly-typed resource class, for looking up localized strings, etc. /// - // 這個類別是自動產生的,是利用 StronglyTypedResourceBuilder - // 類別透過 ResGen 或 Visual Studio 這類工具。 - // 若要加入或移除成員,請編輯您的 .ResX 檔,然後重新執行 ResGen - // (利用 /str 選項),或重建您的 VS 專案。 - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")] + // This class was auto-generated by the StronglyTypedResourceBuilder + // class via a tool like ResGen or Visual Studio. + // To add or remove a member, edit your .ResX file then rerun ResGen + // with the /str option, or rebuild your VS project. + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] public class DefaultConfigResource { @@ -33,7 +33,7 @@ namespace MinecraftClient { } /// - /// 傳回這個類別使用的快取的 ResourceManager 執行個體。 + /// Returns the cached ResourceManager instance used by this class. /// [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] public static global::System.Resources.ResourceManager ResourceManager { @@ -47,8 +47,8 @@ namespace MinecraftClient { } /// - /// 覆寫目前執行緒的 CurrentUICulture 屬性,對象是所有 - /// 使用這個強類型資源類別的資源查閱。 + /// Overrides the current thread's CurrentUICulture property for all + /// resource lookups using this strongly typed resource class. /// [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] public static global::System.Globalization.CultureInfo Culture { @@ -61,8 +61,133 @@ namespace MinecraftClient { } /// - /// 查詢類似 # Minecraft Console Client v1.16.3 - ///# Startup Config File + /// Looks up a localized string similar to ╔═════════════════════════════════════╗ + ///║ Brewing Stand ║ + ///║ ╔═══╗ ⡈ ⠄╔═══╗ ║ + ///║ ║ 4 ╟───╮ ⢠⡐⢈║ 3 ║ ┃ ║ + ///║ ╚═══╝ ╭─╯ ⠂⡠⢂╚╦╦╦╝ ┃ ║ + ///║ ╰───■■■■ ║║║ ▼ ║ + ///║ ╔═══╦═╝║╚═╦═══╗ ║ + ///║ ║ 0 ║╔═╩═╗║ 2 ║ ║ + ///║ ╚═══╝║ 1 ║╚═══╝ ║ + ///║ Inventory ╚═══╝ ║ + ///║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ + ///║║ 5 ║ 6 ║ 7 ║ 8 ║ 9 ║10 ║11 ║12 ║13 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬══ [rest of string was truncated]";. + /// + public static string ContainerType_BrewingStand { + get { + return ResourceManager.GetString("ContainerType_BrewingStand", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to ╔═════════════════════════════════════╗ + ///║ Crafting ║ + ///║ ╔═══╦═══╦═══╗ ║ + ///║ ║ 1 ║ 2 ║ 3 ║ ║ + ///║ ╠═══╬═══╬═══╣ ╔═══╗ ║ + ///║ ║ 4 ║ 5 ║ 6 ║ ━━▶ ║ 0 ║ ║ + ///║ ╠═══╬═══╬═══╣ ╚═══╝ ║ + ///║ ║ 7 ║ 8 ║ 9 ║ ║ + ///║ ╚═══╩═══╩═══╝ ║ + ///║ Inventory ║ + ///║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ + ///║║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║18 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬══ [rest of string was truncated]";. + /// + public static string ContainerType_Crafting { + get { + return ResourceManager.GetString("ContainerType_Crafting", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to ╔═════════════════════════════════════╗ + ///║ Container ║ + ///║ ╔═══╦═══╦═══╗ ║ + ///║ ║ 0 ║ 1 ║ 2 ║ ║ + ///║ ╠═══╬═══╬═══╣ ║ + ///║ ║ 3 ║ 4 ║ 5 ║ ║ + ///║ ╠═══╬═══╬═══╣ ║ + ///║ ║ 6 ║ 7 ║ 8 ║ ║ + ///║ ╚═══╩═══╩═══╝ ║ + ///║ Inventory ║ + ///║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ + ///║║ 9 ║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬══ [rest of string was truncated]";. + /// + public static string ContainerType_Generic_3x3 { + get { + return ResourceManager.GetString("ContainerType_Generic_3x3", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to ╔═════════════════════════════════════╗ + ///║ Chest ║ + ///║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ + ///║║ 0 ║ 1 ║ 2 ║ 3 ║ 4 ║ 5 ║ 6 ║ 7 ║ 8 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ + ///║║ 9 ║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ + ///║║18 ║19 ║20 ║21 ║22 ║23 ║24 ║25 ║26 ║║ + ///║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ + ///║ Inventory ║ + ///║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ + ///║║27 ║28 ║29 ║30 ║31 ║32 ║33 ║34 ║35 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬══ [rest of string was truncated]";. + /// + public static string ContainerType_Generic_9x3 { + get { + return ResourceManager.GetString("ContainerType_Generic_9x3", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to ╔═════════════════════════════════════╗ + ///║ Large Container ║ + ///║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ + ///║║ 0 ║ 1 ║ 2 ║ 3 ║ 4 ║ 5 ║ 6 ║ 7 ║ 8 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ + ///║║ 9 ║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ + ///║║18 ║19 ║20 ║21 ║22 ║23 ║24 ║25 ║26 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ + ///║║27 ║28 ║29 ║30 ║31 ║32 ║33 ║34 ║35 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ + ///║║36 ║37 ║38 ║39 ║40 ║41 ║42 ║43 ║44 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬══ [rest of string was truncated]";. + /// + public static string ContainerType_Generic_9x6 { + get { + return ResourceManager.GetString("ContainerType_Generic_9x6", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to ╔═════════════════════════════════════╗ + ///║╔═══╦═══════════╗ ║ + ///║║ 5 ║ ███ ║ ╔═══╦═══╗ ║ + ///║╠═══╣ ███ ║ ║ 1 ║ 2 ║ ╔═══╗║ + ///║║ 6 ║ ███████ ║ ╠═══╬═══╣━━▶║ 0 ║║ + ///║╠═══╣ ███████ ║ ║ 3 ║ 4 ║ ╚═══╝║ + ///║║ 7 ║ ███████ ║ ╚═══╩═══╝ ║ + ///║╠═══╣ ███ ╠═══╗ ║ + ///║║ 8 ║ ███ ║45 ║ ║ + ///║╚═══╩═══════════╩═══╝ ║ + ///║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ + ///║║ 9 ║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║║ + ///║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬══ [rest of string was truncated]";. + /// + public static string ContainerType_PlayerInventory { + get { + return ResourceManager.GetString("ContainerType_PlayerInventory", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to # Startup Config File /// ///[Main] /// @@ -73,14 +198,15 @@ namespace MinecraftClient { ///login= ///password= ///serverip= + ///type=mojang # Account type. mojang or microsoft + ///method=mcc # Microsoft Account sign-in method. mcc OR browser /// ///# Advanced settings /// ///language=en_GB ///consoletitle=%username%@%serverip% - Minecraft Console Client ///internalcmdchar=slash # Use 'none', 'slash' or 'backslash' - ///splitmessagedelay=2 # Seconds between each part of a long message - ///botowners=Player1,Player2,Player3 # Name list or [字串的其餘部分已遭截斷]"; 的當地語系化字串。 + ///messagec [rest of string was truncated]";. /// public static string MinecraftClient { get { @@ -89,18 +215,19 @@ namespace MinecraftClient { } /// - /// 查詢類似 [mcc] + /// Looks up a localized string similar to [mcc] ///# Messages from MCC itself - ///mcc.description=Console Client for MC {0} to {1} - v{2} - By ORelio & Contributors - ///mcc.keyboard_debug=Keyboard debug mode: Press any key to display info - ///mcc.setting=Loading Settings from {0} ///mcc.login=Login : ///mcc.login_basic_io=Please type the username or email of your choice. ///mcc.password=Password : ///mcc.password_basic_io=Please type the password for {0}. ///mcc.password_hidden=Password : {0} ///mcc.offline=§8You chose to run in offline mode. - ///mcc.session_invalid=§8Cach [字串的其餘部分已遭截斷]"; 的當地語系化字串。 + ///mcc.session_invalid=§8Cached session is invalid or expired. + ///mcc.session_valid=§8Cached session is still valid for {0}. + ///mcc.connecting=Connecting to {0}... + ///mcc.ip=Server IP : + ///mcc.use_version=§8Using Minecraft version [rest of string was truncated]";. /// public static string TranslationEnglish { get { diff --git a/MinecraftClient/DefaultConfigResource.resx b/MinecraftClient/DefaultConfigResource.resx index da58701d..31fd5f0e 100644 --- a/MinecraftClient/DefaultConfigResource.resx +++ b/MinecraftClient/DefaultConfigResource.resx @@ -118,6 +118,24 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + resources\containers\containertype.brewingstand.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 + + + resources\containers\containertype.crafting.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 + + + resources\containers\containertype.generic_3x3.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 + + + resources\containers\containertype.generic_9x3.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 + + + resources\containers\containertype.generic_9x6.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 + + + resources\containers\containertype.playerinventory.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 + Resources\config\MinecraftClient.ini;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8 diff --git a/MinecraftClient/Inventory/ContainerTypeExtensions.cs b/MinecraftClient/Inventory/ContainerTypeExtensions.cs index a93936c0..2ef20660 100644 --- a/MinecraftClient/Inventory/ContainerTypeExtensions.cs +++ b/MinecraftClient/Inventory/ContainerTypeExtensions.cs @@ -40,5 +40,39 @@ namespace MinecraftClient.Inventory default: return 0; } } + + /// + /// Get an ASCII art representation of the container + /// + /// + /// ASCII art representation or NULL if not implemented for this container type + public static string GetAsciiArt(this ContainerType c) + { + switch (c) + { + case ContainerType.PlayerInventory: return DefaultConfigResource.ContainerType_PlayerInventory; + case ContainerType.Generic_9x3: return DefaultConfigResource.ContainerType_Generic_9x3; + case ContainerType.Generic_9x6: return DefaultConfigResource.ContainerType_Generic_9x6; + case ContainerType.Generic_3x3: return DefaultConfigResource.ContainerType_Generic_3x3; + case ContainerType.Crafting: return DefaultConfigResource.ContainerType_Crafting; + case ContainerType.BlastFurnace: return null; + case ContainerType.Furnace: return null; + case ContainerType.Smoker: return null; + case ContainerType.Enchantment: return null; + case ContainerType.BrewingStand: return DefaultConfigResource.ContainerType_BrewingStand; + case ContainerType.Merchant: return null; + case ContainerType.Beacon: return null; + case ContainerType.Anvil: return null; + case ContainerType.Hopper: return null; + case ContainerType.ShulkerBox: return null; + case ContainerType.Loom: return null; + case ContainerType.Stonecutter: return null; + case ContainerType.Lectern: return null; + case ContainerType.Cartography: return null; + case ContainerType.Grindstone: return null; + case ContainerType.Unknown: return null; + default: return null; + } + } } } diff --git a/MinecraftClient/MinecraftClient.csproj b/MinecraftClient/MinecraftClient.csproj index 1dccb4a7..86682d0d 100644 --- a/MinecraftClient/MinecraftClient.csproj +++ b/MinecraftClient/MinecraftClient.csproj @@ -393,6 +393,12 @@ + + + + + + diff --git a/MinecraftClient/Resources/config/MinecraftClient.ini b/MinecraftClient/Resources/config/MinecraftClient.ini index 192f2216..eb613401 100644 --- a/MinecraftClient/Resources/config/MinecraftClient.ini +++ b/MinecraftClient/Resources/config/MinecraftClient.ini @@ -27,6 +27,7 @@ privatemsgscmdname=tell # Used by RemoteControl bot showsystemmessages=true # System messages for server ops showxpbarmessages=true # Messages displayed above xp bar showchatlinks=true # Show links embedded in chat messages +showinventorylayout=true # Show inventory layout as ASCII art in inventory command terrainandmovements=false # Uses more ram, cpu, bandwidth inventoryhandling=false # Toggle inventory handling (beta) entityhandling=false # Toggle entity handling (beta) diff --git a/MinecraftClient/Resources/containers/ContainerType.BrewingStand.txt b/MinecraftClient/Resources/containers/ContainerType.BrewingStand.txt new file mode 100644 index 00000000..c94ae40a --- /dev/null +++ b/MinecraftClient/Resources/containers/ContainerType.BrewingStand.txt @@ -0,0 +1,22 @@ +╔═════════════════════════════════════╗ +║ Brewing Stand ║ +║ ╔═══╗ ⡈ ⠄╔═══╗ ║ +║ ║ 4 ╟───╮ ⢠⡐⢈║ 3 ║ ┃ ║ +║ ╚═══╝ ╭─╯ ⠂⡠⢂╚╦╦╦╝ ┃ ║ +║ ╰───■■■■ ║║║ ▼ ║ +║ ╔═══╦═╝║╚═╦═══╗ ║ +║ ║ 0 ║╔═╩═╗║ 2 ║ ║ +║ ╚═══╝║ 1 ║╚═══╝ ║ +║ Inventory ╚═══╝ ║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║ 5 ║ 6 ║ 7 ║ 8 ║ 9 ║10 ║11 ║12 ║13 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║14 ║15 ║16 ║17 ║18 ║19 ║20 ║21 ║22 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║23 ║24 ║25 ║26 ║27 ║28 ║29 ║30 ║31 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║32 ║33 ║34 ║35 ║36 ║37 ║38 ║39 ║40 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║ 1 2 3 4 5 6 7 8 9 ║ +╚═════════════════════════════════════╝ \ No newline at end of file diff --git a/MinecraftClient/Resources/containers/ContainerType.Crafting.txt b/MinecraftClient/Resources/containers/ContainerType.Crafting.txt new file mode 100644 index 00000000..36865cee --- /dev/null +++ b/MinecraftClient/Resources/containers/ContainerType.Crafting.txt @@ -0,0 +1,22 @@ +╔═════════════════════════════════════╗ +║ Crafting ║ +║ ╔═══╦═══╦═══╗ ║ +║ ║ 1 ║ 2 ║ 3 ║ ║ +║ ╠═══╬═══╬═══╣ ╔═══╗ ║ +║ ║ 4 ║ 5 ║ 6 ║ ━━▶ ║ 0 ║ ║ +║ ╠═══╬═══╬═══╣ ╚═══╝ ║ +║ ║ 7 ║ 8 ║ 9 ║ ║ +║ ╚═══╩═══╩═══╝ ║ +║ Inventory ║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║18 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║19 ║20 ║21 ║22 ║23 ║24 ║25 ║26 ║27 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║28 ║29 ║30 ║31 ║32 ║33 ║34 ║35 ║36 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║37 ║38 ║39 ║40 ║41 ║42 ║43 ║44 ║45 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║ 1 2 3 4 5 6 7 8 9 ║ +╚═════════════════════════════════════╝ \ No newline at end of file diff --git a/MinecraftClient/Resources/containers/ContainerType.Generic_3x3.txt b/MinecraftClient/Resources/containers/ContainerType.Generic_3x3.txt new file mode 100644 index 00000000..9499be24 --- /dev/null +++ b/MinecraftClient/Resources/containers/ContainerType.Generic_3x3.txt @@ -0,0 +1,22 @@ +╔═════════════════════════════════════╗ +║ Container ║ +║ ╔═══╦═══╦═══╗ ║ +║ ║ 0 ║ 1 ║ 2 ║ ║ +║ ╠═══╬═══╬═══╣ ║ +║ ║ 3 ║ 4 ║ 5 ║ ║ +║ ╠═══╬═══╬═══╣ ║ +║ ║ 6 ║ 7 ║ 8 ║ ║ +║ ╚═══╩═══╩═══╝ ║ +║ Inventory ║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║ 9 ║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║18 ║19 ║20 ║21 ║22 ║23 ║24 ║25 ║26 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║27 ║28 ║29 ║30 ║31 ║32 ║33 ║34 ║35 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║36 ║37 ║38 ║39 ║40 ║41 ║42 ║43 ║44 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║ 1 2 3 4 5 6 7 8 9 ║ +╚═════════════════════════════════════╝ \ No newline at end of file diff --git a/MinecraftClient/Resources/containers/ContainerType.Generic_9x3.txt b/MinecraftClient/Resources/containers/ContainerType.Generic_9x3.txt new file mode 100644 index 00000000..f1fd821e --- /dev/null +++ b/MinecraftClient/Resources/containers/ContainerType.Generic_9x3.txt @@ -0,0 +1,22 @@ +╔═════════════════════════════════════╗ +║ Chest ║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║ 0 ║ 1 ║ 2 ║ 3 ║ 4 ║ 5 ║ 6 ║ 7 ║ 8 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║ 9 ║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║18 ║19 ║20 ║21 ║22 ║23 ║24 ║25 ║26 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║ Inventory ║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║27 ║28 ║29 ║30 ║31 ║32 ║33 ║34 ║35 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║36 ║37 ║38 ║39 ║40 ║41 ║42 ║43 ║44 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║45 ║46 ║47 ║48 ║49 ║50 ║51 ║52 ║53 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║54 ║55 ║56 ║57 ║58 ║59 ║60 ║61 ║62 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║ 1 2 3 4 5 6 7 8 9 ║ +╚═════════════════════════════════════╝ \ No newline at end of file diff --git a/MinecraftClient/Resources/containers/ContainerType.Generic_9x6.txt b/MinecraftClient/Resources/containers/ContainerType.Generic_9x6.txt new file mode 100644 index 00000000..4a5a2080 --- /dev/null +++ b/MinecraftClient/Resources/containers/ContainerType.Generic_9x6.txt @@ -0,0 +1,28 @@ +╔═════════════════════════════════════╗ +║ Large Container ║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║ 0 ║ 1 ║ 2 ║ 3 ║ 4 ║ 5 ║ 6 ║ 7 ║ 8 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║ 9 ║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║18 ║19 ║20 ║21 ║22 ║23 ║24 ║25 ║26 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║27 ║28 ║29 ║30 ║31 ║32 ║33 ║34 ║35 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║36 ║37 ║38 ║39 ║40 ║41 ║42 ║43 ║44 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║45 ║46 ║47 ║48 ║49 ║50 ║51 ║52 ║53 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║ Inventory ║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║54 ║55 ║56 ║57 ║58 ║59 ║60 ║61 ║62 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║63 ║64 ║65 ║66 ║67 ║68 ║69 ║70 ║71 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║72 ║73 ║74 ║75 ║76 ║77 ║78 ║79 ║80 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║81 ║82 ║83 ║84 ║85 ║86 ║87 ║88 ║89 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║ 1 2 3 4 5 6 7 8 9 ║ +╚═════════════════════════════════════╝ \ No newline at end of file diff --git a/MinecraftClient/Resources/containers/ContainerType.PlayerInventory.txt b/MinecraftClient/Resources/containers/ContainerType.PlayerInventory.txt new file mode 100644 index 00000000..e8cefb1d --- /dev/null +++ b/MinecraftClient/Resources/containers/ContainerType.PlayerInventory.txt @@ -0,0 +1,22 @@ +╔═════════════════════════════════════╗ +║╔═══╦═══════════╗ ║ +║║ 5 ║ ███ ║ ╔═══╦═══╗ ║ +║╠═══╣ ███ ║ ║ 1 ║ 2 ║ ╔═══╗║ +║║ 6 ║ ███████ ║ ╠═══╬═══╣━━▶║ 0 ║║ +║╠═══╣ ███████ ║ ║ 3 ║ 4 ║ ╚═══╝║ +║║ 7 ║ ███████ ║ ╚═══╩═══╝ ║ +║╠═══╣ ███ ╠═══╗ ║ +║║ 8 ║ ███ ║45 ║ ║ +║╚═══╩═══════════╩═══╝ ║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║ 9 ║10 ║11 ║12 ║13 ║14 ║15 ║16 ║17 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║18 ║19 ║20 ║21 ║22 ║23 ║24 ║25 ║26 ║║ +║╠═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╬═══╣║ +║║27 ║28 ║29 ║30 ║31 ║32 ║33 ║34 ║35 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║╔═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╦═══╗║ +║║36 ║37 ║38 ║39 ║40 ║41 ║42 ║43 ║44 ║║ +║╚═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╩═══╝║ +║ 1 2 3 4 5 6 7 8 9 ║ +╚═════════════════════════════════════╝ \ No newline at end of file diff --git a/MinecraftClient/Settings.cs b/MinecraftClient/Settings.cs index df2badb4..6f96d9c8 100644 --- a/MinecraftClient/Settings.cs +++ b/MinecraftClient/Settings.cs @@ -91,6 +91,7 @@ namespace MinecraftClient public static bool DisplaySystemMessages = true; public static bool DisplayXPBarMessages = true; public static bool DisplayChatLinks = true; + public static bool DisplayInventoryLayout = true; public static bool TerrainAndMovements = false; public static bool InventoryHandling = false; public static string PrivateMsgsCmdName = "tell"; @@ -357,6 +358,7 @@ namespace MinecraftClient case "showsystemmessages": DisplaySystemMessages = str2bool(argValue); return true; case "showxpbarmessages": DisplayXPBarMessages = str2bool(argValue); return true; case "showchatlinks": DisplayChatLinks = str2bool(argValue); return true; + case "showinventorylayout": DisplayInventoryLayout = str2bool(argValue); return true; case "terrainandmovements": TerrainAndMovements = str2bool(argValue); return true; case "entityhandling": EntityHandling = str2bool(argValue); return true; case "enableentityhandling": EntityHandling = str2bool(argValue); return true;