maxpro game

I want plugin for minecraft server 1.21.1 shop gui

Kodari AI
KodariSep 21 at 12:02 pm 2
ShopGUI
A Bukkit/Spigot plugin for Minecraft 1.21.1 that provides a graphical shop interface using the inventory GUI framework. Players can open a shop menu through a command, browse items displayed as clickable inventory buttons, and purchase items with a simple click. The plugin features a centralized GUIManager for handling multiple active shop inventories, lazy-initialized GUI components for optimal performance, and automatic event handling for open, click, and close interactions. Each shop item is configured with custom icons, display names, prices, and purchase actions. The system supports multiple shop categories and items, with clean memory management that automatically unregisters closed inventories. Built on the reusable InventoryGUI framework with button-based architecture, allowing easy extension for additional shop types or features.

Created a complete Minecraft 1.21.1 ShopGUI plugin with:

  • Configurable category-based shop GUI

  • Buy and sell actions using left/right click

  • Pagination support

  • Internal balance system stored in balances.yml

  • /shop, /shop balance, /shop give, and /shop reload

  • Permission nodes:

    • shop.use

    • shop.admin

  • XSeries material compatibility

  • Example categories for blocks, ores, and food

  • Gradle project targeting Java 21 and Paper 1.21.1

maxpro game

hey you make very nice but add more items and add sellgui

Kodari AI
KodariSep 21 at 12:16 pm 1
  1. Expand the shop catalog with additional configurable items.

  2. Add a sell GUI with sell prices, click handling, and command access.

  1. Added many more shop items across blocks, ores, and food categories.

  2. Added a complete sell GUI:

    • /shop sell

    • “Sell items” button inside the shop menus

    • Left-click sells the configured package amount

    • Right-click sells all matching items in the player’s inventory

    • Pagination support

    • Balance and navigation buttons

  3. Updated command usage and tab completion.

  4. Added configurable sell GUI settings in config.yml.

maxpro game

hey i say add more items you not add pls add and i dont want this command i wand /sellgui

Kodari AI
KodariSep 21 at 1:19 pm 1
  1. Add a substantially larger default item catalog to the shop configuration.

  2. Make /sellgui the dedicated sell GUI command and update command registration/help accordingly.

  1. Added many new shop items, including:

    • Building blocks: sand, gravel, sandstone, deepslate, tuff, calcite, obsidian, wood types

    • Ores: copper, quartz, amethyst, raw iron, raw gold, netherite scrap

    • Food: chicken, porkchop, mutton, cod, pumpkin pie, cookies

    • Farming: wheat, seeds, potatoes, beetroot, pumpkins, melons, sugar cane

    • Mob drops: bones, string, gunpowder, ender pearls, slime balls, blaze rods

    • Nether items: netherrack, soul sand, glowstone dust, magma cream, ghast tears

  2. Added the dedicated command:

    Plain Text
    /sellgui
    
  3. Removed the /shop sell subcommand. The sell GUI button inside the shop still works normally.

Permission remains:

Plain Text
shop.use
Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
settings.gradle
Code
14 1,296
src/main/java/com/kodari/shopgui/ShopPlugin.java
package com.kodari.shopgui;

import com.kodari.shopgui.command.ShopCommand;
import com.kodari.shopgui.economy.EconomyManager;
import com.kodari.shopgui.listener.ShopListener;
import com.kodari.shopgui.shop.ShopManager;
import com.kodari.shopgui.shop.ShopMenu;
import com.kodari.shopgui.shop.SellMenu;
import org.bukkit.ChatColor;
import org.bukkit.entity.Player;
import org.bukkit.plugin.java.JavaPlugin;

public final class ShopPlugin extends JavaPlugin {
    private EconomyManager economyManager;
    private ShopManager shopManager;
    private ShopListener shopListener;

    @Override
    public void onEnable() {
        saveDefaultConfig();

        this.economyManager = new EconomyManager(this);
        this.shopManager = new ShopManager(this);
        this.shopListener = new ShopListener();

        getServer().getPluginManager().registerEvents(shopListener, this);
        ShopCommand shopCommand = new ShopCommand(this);
        getCommand("shop").setExecutor(shopCommand);
        getCommand("shop").setTabCompleter(shopCommand);
        getCommand("sellgui").setExecutor(shopCommand);
    }

    @Override
    public void onDisable() {
        if (economyManager != null) {
            economyManager.save();
        }
    }

    public void openShop(Player player) {
        player.closeInventory();
        new ShopMenu(this, player).open();
    }

    public void openSellShop(Player player) {
        player.closeInventory();
        new SellMenu(this, player).open();
    }

    public String message(String key, String... replacements) {
        String value = getConfig().getString("messages." + key, key);
        value = value.replace("{prefix}", getConfig().getString("messages.prefix", ""));
        for (int i = 0; i + 1 < replacements.length; i += 2) {
            value = value.replace("{" + replacements[i] + "}", replacements[i + 1]);
        }
        return color(value);
    }

    public String color(String value) {
        return ChatColor.translateAlternateColorCodes('&', value == null ? "" : value);
    }

    public EconomyManager getEconomyManager() {
        return economyManager;
    }

    public ShopManager getShopManager() {
        return shopManager;
    }

    public ShopListener getShopListener() {
        return shopListener;
    }
}