Build a complete Bukkit/Spigot/Paper Minecraft plugin implementing the user's kit shop. This is a new MINECRAFT_PLUGIN project. User requirements: /kits opens a GUI of kits that can be purchased with their current money (EssentialsX economy through Vault). There are two kit types: PRODUCT kits can be bought repeatedly at the listed cost; PASS kits are purchased only once, then can be used/equipped free thereafter. /kit create (permission-gated) snapshots the creator's entire inventory, armor, offhand and held item with full ItemStack metadata/NBT, then allows configuring kit name, cost, product/pass type, GUI display item, and description. /kit edit <kit name> allows adding/removing/rearranging kit items by dragging items in a GUI, including hotbar, main inventory, armor and offhand where the server API permits. /kit buy <kit name> purchases (or uses an owned pass) and equips it; /kit <kit name> equips a kit the player owns or can afford, with clear feedback for unavailable/insufficient funds; /kit auto <kit name> toggles auto-equip for that kit and bare /kit auto toggles auto-equip on/off. In the kits GUI, shift-click toggles auto-equip for that kit. Auto-equip applies the configured kit on player death/respawn when eligible. Equipping with an empty inventory should proceed without confirmation; if inventory has items, present a confirmation GUI before replacing/clearing it. Implement death-based re-equip timing with configurable defaults matching the examples: a 10-minute re-equip window after a valid death, deaths within 5 minutes of receiving/equipping a kit do not reset/bypass its timer, and repeated kills by the same player within 10 minutes do not reset/bypass the timer. Expose these timings as config settings and provide safe, understandable behavior/messages; never silently delete items without explicit confirmation.

Implementation expectations:

  • First inspect the generated project/template and use its actual Bukkit API/version and conventions. Produce working source, plugin descriptor, config, and any needed commands/listeners/GUI classes.
  • Use Vault's Economy API and declare Vault appropriately (soft-dependency/dependency as needed); gracefully disable economy-backed actions with an actionable message if Vault/economy is absent. EssentialsX should work as the Vault provider, but do not hard-couple to EssentialsX internals.
  • Persist kits (including serialized ItemStacks with full metadata), ownership/pass purchases, auto-equip settings, and required cooldown/death state across restarts. Use robust YAML or the template's persistence pattern; avoid loss/corruption on reload.
  • Add permission nodes and sensible defaults in plugin.yml, including a create/edit/admin permission and ordinary player access. Validate kit names, costs, inventory operations, offline/dead players and GUI click/drag exploits. Protect GUI inventories from taking items except intended editor actions; cancel normal inventory interactions while an editor is open, while allowing deliberate drag placement/removal. Do not let players exploit GUI buttons as items.
  • Make /kit create guide the user through a reliable creation flow. A practical flow is capture current inventory, then open an editor with controls for kit name/type/cost/display item/description/save/cancel; provide clear chat prompts if needed. /kit edit should open the same editable layout and save after edits. Build an actual GUI section/layout that lets the creator arrange hotbar, inventory, armor, and offhand; preserve exact item data and slots.
  • /kits GUI should show each kit's configured display item, name, type, cost/owned state, description and purchase/use feedback. Support normal click for purchase/use and shift-click for auto-toggle. Avoid charging again for an already-owned PASS.
  • Confirmation UI must have explicit confirm/cancel and explain whether the player's items will be overwritten; cancel leaves inventory unchanged. Handle armor/offhand and all relevant Bukkit inventory slots correctly, and ensure applying a kit does not accidentally duplicate contents.
  • Implement clear, documented config defaults/messages, sensible async-safe file persistence, and helpful error handling. Keep the feature set focused on this request; do not invent unrelated systems.
  • Finish with a concise report listing commands, permissions, config defaults and any API limitations. Do not claim to have compiled or tested; the workspace will run the actual compile.
Kodari AI
KodariOct 4 at 11:21 pm 3
KitShopPro
A comprehensive kit shop plugin for Bukkit/Spigot/Paper servers. Players browse and purchase kits via a GUI, with two types: PRODUCT (repeatable purchases) and PASS (one-time purchase, free equips thereafter). Includes kit creation/editing GUIs with full inventory snapshot including armor and offhand, auto-equip on death/respawn with configurable timers, confirmation dialogs before inventory replacement, Vault economy integration, and persistent YAML storage for kits, ownership, and settings.
  1. Build the plugin entry point, configuration, kit/profile persistence, and Vault economy hook.

  2. Add /kit and /kits, editor and shop GUIs, inventory confirmation, and death/respawn auto-equip handling.

  3. Define permissions and sensible defaults in the plugin descriptor and config.

Implemented KodariKitShop with Vault-backed purchases, persistent kits and player settings, shop/editor/confirmation GUIs, and death-based auto-equip.

Commands

  • /kits — open the shop; click to buy or use a kit, shift-click to toggle its auto-equip.

  • /kit <name> — use an owned PASS or purchase and equip the kit.

  • /kit buy <name> — purchase/use and equip a kit.

  • /kit auto [name] — toggle global auto-equip, or toggle it for one kit.

  • /kit create — snapshot your inventory and open the guided editor.

  • /kit edit <name> — edit a kit’s items and settings.

Permissions

  • kits.use, kits.auto — default true

  • kits.create, kits.edit, kits.admin — default op; kits.admin also grants create/edit access.

Timing defaults in config.yml: 600 seconds for the death re-equip window, 300 seconds minimum after receiving/equipping a kit, and 600 seconds before a repeat kill by the same player can count as a new valid death. Kits and player state are saved to YAML files.

Paid actions use Vault’s economy provider; EssentialsX can provide it. Vault is a soft dependency, and paid actions show an actionable message if no provider is available. Inventory, armor, offhand, and cursor contents require explicit confirmation before replacement.

API limitation: kit items are stored using Bukkit’s ItemStack YAML serialization, preserving metadata the server API serializes. Opaque NBT added by another plugin is preserved only if that plugin’s data is exposed through Bukkit’s item serialization.

F

Rename it to PetrolKits use small caps and I want the branding in game to be basic

Kodari AI
KodariOct 4 at 11:22 pm 1

The generation was stopped before any content could be produced.

F

Rename it to PetrolKits use small caps and I want the branding in game to be basic,also left click to buy and right click to preview full kit,shift right click to organise and shift left click to toggle auto

Kodari AI
KodariOct 4 at 11:27 pm 1
  1. Rename the plugin and simplify its in-game branding.

  2. Update /kits clicks: left-click buy/use, right-click preview, shift-right-click organize, shift-left-click auto-toggle.

Renamed the plugin to PetrolKits and simplified its in-game branding with a small-caps, gray prefix and a plain shop title.

The /kits GUI now supports:

  • Left-click: buy/equip

  • Right-click: preview the full kit

  • Shift-right-click: organize/edit the kit (kits.edit or kits.admin)

  • Shift-left-click: toggle auto-equip (kits.auto)

Updated the GUI instructions and item lore to match.

F

No what I mean for the player if they don't want a certain item in their offHand they can replace it with something in their offHand kinda like how the pvp club kit organise works you can't add new items but you can change their position

Kodari AI
KodariOct 4 at 11:31 pm 1

Plan:

  1. Make shift-right-click open a personal kit organizer for every player, not the shared admin editor.

  2. Let players swap kit slots—including offhand—with existing kit items only, and persist their slot arrangement.

  3. Apply the saved arrangement when previewing or equipping the kit.

Shift-right-click now opens a personal kit organizer—no edit permission required. Select two kit slots to swap their contents, including offhand, armor, hotbar, and empty slots. It only rearranges the kit’s existing items; it can’t add new items. Save your layout to keep it for future equips, or cancel to discard changes. Your arrangement is stored per player and reflected in previews and equips.

F

Problem I can't delete kits

Kodari AI
KodariOct 5 at 12:27 am 1
  1. Add /kit delete <name> for admins, persist deletion, and remove the kit’s saved player references.

Added /kit delete <kit name> for players with kits.delete or kits.admin. Deleting a kit now saves the change and clears its saved auto-equip, pass ownership, and organization data.

F

Another one i can literally put totems in my armor slots and the gui is kinda bad for reorganizing

Kodari AI
KodariOct 5 at 12:31 am 1
  1. Prevent organizer clicks from moving items into armor slots unless they’re valid armor.

  2. Improve the organizer layout and controls so slot swapping is clearer.

Fixed the organizer so totems and other non-armor items can’t be swapped into armor slots. The layout now resembles an inventory: armor and offhand are shown separately above storage and hotbar, with glass marking empty slots. Click a slot, then its destination to swap—including moving an item to or from the offhand.

Kodari can make mistakes. Review important code before using.
Files
src
Code
12 1,925
src/main/java/com/kodari/kitshop/KitShopPlugin.java
package com.kodari.kitshop;

import com.kodari.kitshop.command.KitCommand;
import com.kodari.kitshop.economy.EconomyHook;
import com.kodari.kitshop.economy.VaultEconomyHook;
import com.kodari.kitshop.gui.KitGuiListener;
import com.kodari.kitshop.listener.KitListener;
import com.kodari.kitshop.manager.KitManager;
import com.kodari.kitshop.storage.KitStorage;
import org.bukkit.ChatColor;
import org.bukkit.command.CommandSender;
import org.bukkit.plugin.java.JavaPlugin;

public final class KitShopPlugin extends JavaPlugin {
    private KitManager kitManager;
    private KitGuiListener guiListener;

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

        KitStorage storage = new KitStorage(this);
        storage.load();

        EconomyHook economy = null;
        if (getServer().getPluginManager().getPlugin("Vault") != null) {
            VaultEconomyHook vaultHook = new VaultEconomyHook(this);
            economy = vaultHook;
        }
        if (economy == null || !economy.isAvailable()) {
            getLogger().warning("Vault or a Vault economy provider was not found. Paid kit actions are unavailable until one is installed.");
        }

        kitManager = new KitManager(this, storage, economy);
        guiListener = new KitGuiListener(this, kitManager);
        getServer().getPluginManager().registerEvents(guiListener, this);
        getServer().getPluginManager().registerEvents(new KitListener(this, kitManager, guiListener), this);

        KitCommand command = new KitCommand(this, kitManager, guiListener);
        getCommand("kit").setExecutor(command);
        getCommand("kit").setTabCompleter(command);
        getCommand("kits").setExecutor(command);
        getCommand("kits").setTabCompleter(command);
    }

    @Override
    public void onDisable() {
        if (kitManager != null) {
            kitManager.saveAll();
        }
    }

    public void message(CommandSender sender, String key, String... replacements) {
        sender.sendMessage(ChatColor.translateAlternateColorCodes('&',
                getConfig().getString("messages.prefix", "") + text(key, replacements)));
    }

    public String text(String key, String... replacements) {
        String value = getConfig().getString("messages." + key, "&cMissing message: " + key);
        for (int i = 0; i + 1 < replacements.length; i += 2) {
            value = value.replace(replacements[i], replacements[i + 1]);
        }
        return ChatColor.translateAlternateColorCodes('&', value);
    }
}