mayank099166

I need a plugin for item crafting recipe locker

Kodari AI
KodariMay 22 at 5:58 am 11,475 (v2)

I’ll create a crafting recipe management plugin with locking/unlocking capabilities and GUI support.

RecipeLocker
A crafting recipe management system that locks recipes by default and allows unlocking them per-player. Features include recipe discovery mechanics, admin commands to grant/revoke recipes, persistent data storage, prevention of locked recipe crafting, and an interactive GUI to view locked/unlocked recipes. Perfect for progression-based servers where players unlock crafting recipes through gameplay or achievements.

Project created! RecipeLocker is a complete crafting recipe management system with:

Core Features:

  • Lock/unlock recipes per-player with persistent storage

  • Prevent crafting of locked recipes

  • Admin commands (/rl unlock/lock/reset/list/view)

  • Interactive GUI showing locked/unlocked recipes

  • Automatic data saving/loading

Architecture:

  • RecipeManager - Handles recipe locking logic

  • DataManager - YAML-based persistence per player

  • PlayerRecipeData - Stores unlocked recipes per UUID

  • CraftListener - Blocks locked recipe crafting

  • Full GUI system with button-based interactions

Commands:

  • /rl unlock <player> <recipe> - Grant recipe access

  • /rl lock <player> <recipe> - Revoke recipe access

  • /rl reset <player> - Clear all unlocked recipes

  • /rl list [player] - Show unlocked recipes

  • /rl view [player] - Open interactive recipe book GUI

The plugin uses XSeries for cross-version compatibility and follows lazy initialization patterns to prevent field ordering issues. All data persists in playerdata/ folder as YAML files.

mayank099166

I need file the items of diamond and netherite

mayank099166

I need locker for diamonds items and netherite items

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
15 872
src/main/java/com/recipelocker/RecipeLocker.java
package com.recipelocker;

import com.recipelocker.command.RecipeCommand;
import com.recipelocker.inventory.gui.GUIListener;
import com.recipelocker.inventory.gui.GUIManager;
import com.recipelocker.listener.CraftListener;
import com.recipelocker.manager.DataManager;
import com.recipelocker.manager.RecipeManager;
import org.bukkit.Bukkit;
import org.bukkit.plugin.java.JavaPlugin;

public class RecipeLocker extends JavaPlugin {
    private RecipeManager recipeManager;
    private DataManager dataManager;
    private GUIManager guiManager;
    
    @Override
    public void onEnable() {
        saveDefaultConfig();
        
        this.recipeManager = new RecipeManager(this);
        this.dataManager = new DataManager(this);
        this.guiManager = new GUIManager();
        
        this.dataManager.loadAllData();
        
        Bukkit.getPluginManager().registerEvents(new CraftListener(this), this);
        Bukkit.getPluginManager().registerEvents(new GUIListener(guiManager), this);
        
        getCommand("recipelocker").setExecutor(new RecipeCommand(this));
        
        getLogger().info("RecipeLocker enabled!");
    }
    
    @Override
    public void onDisable() {
        this.dataManager.saveAllData();
        getLogger().info("RecipeLocker disabled!");
    }
    
    public RecipeManager getRecipeManager() {
        return recipeManager;
    }
    
    public DataManager getDataManager() {
        return dataManager;
    }
    
    public GUIManager getGuiManager() {
        return guiManager;
    }
}