GrzybcioRynek

Categories

MarketCategory enum and material mapping — axes are weapons, not tools.

Compatible with: GrzybcioRynek 1.0.3Minecraft 26.2Web 0.1.0

Based on GrzybcioRynek 1.0.3 and web 0.1.0 source.

Categories are the enum com.example.marketplace.inventory.MarketCategory. Filtering runs server-side in matches(MarketListing). Button icons and slots live in gui.ymlbrowse.categories and are used by MarketCategoryGUI.

You cannot add a new category with YAML alone — you must add an enum value and a matches rule. Guide: Developer → Add a category.

List

EnumYAML / message keyDefault slotButton material
ALLall / gui.category.all10NETHER_STAR
TOOLStools11DIAMOND_PICKAXE
WEAPONSweapons12DIAMOND_SWORD
ARMORarmor13DIAMOND_CHESTPLATE
BLOCKSblocks14GRASS_BLOCK
FOODfood15COOKED_BEEF
FARMINGfarming16WHEAT
REDSTONEredstone19REDSTONE
DECORATIONSdecorations20PAINTING
POTIONSpotions21POTION
ENCHANTED_BOOKSenchanted_books22ENCHANTED_BOOK
OTHERother23CHEST

ALL always returns true. OTHER is whatever did not match any other category (except ALL).

What goes where

TOOLS

*_PICKAXE, *_SHOVEL, *_HOE, FISHING_ROD, SHEARS, FLINT_AND_STEEL, BRUSH, CARROT_ON_A_STICK, WARPED_FUNGUS_ON_A_STICK.

Warning

*_AXE is not a tool. Axes are in WEAPONS.

WEAPONS

  • *_SWORD, *_SPEAR, *_AXE, MACE
  • TRIDENT, BOW, CROSSBOW
  • projectiles: ARROW, SPECTRAL_ARROW, TIPPED_ARROW, SNOWBALL, EGG, ENDER_PEARL, FIRE_CHARGE, WIND_CHARGE

ARMOR

*_HELMET, *_CHESTPLATE, *_LEGGINGS, *_BOOTS, *_HORSE_ARMOR, SHIELD, ELYTRA, TURTLE_HELMET, CARVED_PUMPKIN, TOTEM_OF_UNDYING.

BLOCKS

material.isBlock(), but not a tool and not a decoration.

FOOD

material.isEdible() or CAKE or MILK_BUCKET.

FARMING

*_SEEDS, *_SAPLING, name with CROPS, plus e.g. WHEAT, BEETROOT, CARROT, POTATO, BAMBOO, SUGAR_CANE, CACTUS, COCOA_BEANS, MELON, MELON_SLICE, PUMPKIN, BONE_MEAL, COMPOSTER.

REDSTONE

Name contains REDSTONE, plus e.g. REPEATER, COMPARATOR, OBSERVER, HOPPER, DROPPER, DISPENSER, PISTON, STICKY_PISTON, SLIME_BLOCK, HONEY_BLOCK, TARGET, DAYLIGHT_DETECTOR, TRIPWIRE_HOOK, LEVER, *_BUTTON, *_PRESSURE_PLATE, SCULK_SENSOR, CALIBRATED_SCULK_SENSOR.

DECORATIONS

Name contains BANNER, CARPET, CANDLE, FLOWER, POTTED; *_HEAD, *_SKULL; plus PAINTING, ITEM_FRAME, GLOW_ITEM_FRAME, ARMOR_STAND, FLOWER_POT.

POTIONS

POTION, SPLASH_POTION, LINGERING_POTION, EXPERIENCE_BOTTLE, DRAGON_BREATH, GLASS_BOTTLE, or meta PotionMeta.

ENCHANTED_BOOKS

ENCHANTED_BOOK or a normal BOOK with a combat enchant from the COMBAT_ENCHANTMENTS list (sharpness, smite, protection, power, …).

What you can change in YAML

Button slot and material in MarketCategoryGUI. Names: messages.gui.category.*.

You cannot change classification rules without editing MarketCategory.java. You cannot add a 13th category with gui.yml alone — an unknown key does not become an enum.