xpextra._33241

Create a Minecraft Paper 1.20+ plugin called "BooksSMP" with the following features:

  1. SMP Start System:
  • Add command: /smp start
  • When executed:

- Set world border to 4 chunks radius (32x32 area) - Broadcast title to all online players:

Title: "📚 BOOKS SMP STARTED" Subtitle: "Prepare for your destiny..." - Start a 5-minute countdown - After 5 minutes, open a INVENTORY GUI spin animation for all online players - Each player receives 1 unique book randomly - No two players can receive the same book - Extra players (>12) receive no book

  1. BossBar System:
  • Create a global BossBar visible to all online players
  • Text: "📚 BOOKS SMP"
  • Color: configurable (default PURPLE)
  • Style: SOLID
  • Always full progress
  • New players joining after SMP start should automatically see the BossBar
  • Disappear only if SMP is manually ended
  • Optional: If Death Book holder is online, change BossBar to "💀 Death Wielder Alive"
  • Optional: If Death Book holder dies 5 times, temporarily change BossBar to "⚠ Death Power Weakening..."
  1. 12 Custom Books:

Flame, Thunder, Ocean, Shadow, Nature, Ice, Death, Miner, Wind, Time, Beast, Light

  • Each book:

- Custom name, lore, NBT tag - Soulbound to player (cannot drop, trade, move to chest, hopper, item frame) - Remains in inventory on death - Save player-book data (UUID-based) in config/database - 1 passive ability (permanent effect) - 1 active ability (right-click trigger) - Cooldown system - Particle + sound effects

  • Example:

- Flame Book: Passive Fire Resistance, Active Ignite target (10s cooldown) - Death Book: Passive Heal 2 hearts on kill, Active Wither Touch (20s cooldown), Once per day auto revive

  1. 3-Kill Steal System:
  • Track kills between players
  • If Player A kills Player B 3 times:

- Player B's book drops and can be picked up by Player A - Reset counter after steal

  • Rule does NOT apply to Death Book
  1. Death Book Exclusive:
  • Only 1 Death Book exists in entire SMP
  • Randomly assigned at start
  • Cannot drop, move, or be stolen
  • 3-kill steal rule does NOT affect it
  • Remains permanently bound to first assigned player
  • Save holder UUID permanently
  • Remains in inventory on death
  1. INVENTORY GUI Spin System:
  • 5 second animation for book selection
  • Sound and particle effects
  • Final book stops in center slot and automatically gives player their book
  1. Data Management:
  • Save all player data on server shutdown
  • Load correctly on restart
  • Optimized for multiplayer performance
  1. Plugin Requirements:
  • Paper API
  • Clean OOP structure
  • Event listeners separated
  • Config.yml for abilities and cooldowns
  • messages.yml for all text
  • No memory leaks or console errors
Kodari AI
KodariFeb 23 at 4:51 pm 25,778 (v2)

I’ll create a comprehensive Books SMP plugin with all requested features.

BooksSMP
An SMP plugin featuring 12 unique mystical books with custom abilities, a boss bar system, inventory GUI spin animations for book selection, kill-tracking mechanics, and complete data persistence. Each book grants passive and active abilities, with special mechanics for the Death Book and a 3-kill steal system.

Now I’ll create the complete plugin structure:

Plugin complete! Here’s what was created:

Core Features Implemented:

  1. SMP Start System - /smp start sets world border to 4 chunks, shows title, starts 5-min countdown

  2. BossBar System - Global purple boss bar that updates based on Death Book holder status

  3. 12 Custom Books - Each with unique passive/active abilities, NBT tags, and soulbound mechanics

  4. Book Spin GUI - 5-second animation that distributes books randomly (max 12 players)

  5. 3-Kill Steal System - Tracks kills and transfers books after 3 kills (except Death Book)

  6. Death Book Special - Cannot be stolen, daily auto-revive, heal on kill, weakening mechanic

  7. Data Persistence - Saves player data, kill counts, book assignments to playerdata.yml

  8. Book Protection - Cannot drop, trade, move to chests, or lose on death

All abilities use XSeries for cross-version compatibility, includes sound/particle effects, cooldown system, and proper OOP structure with managers separating concerns.

xpextra._33241

Add This Command /booksmp give book And /smp start 5mint later world is 10000000 oky

Kodari AI
KodariMar 25 at 5:41 pm 15,353 (v2)

I’ll add these commands. Let me first read the existing files to understand the structure.

I’ll add these commands:

  • /booksmp give book to give books to players

  • Modified /smp start to set world border to 10,000,000 after 5 minute countdown

Commands added successfully:

  • /booksmp give <player> <book> - Give any book to a player with tab completion

  • /smp start - Now expands world border to 10,000,000 blocks after the 5-minute countdown completes

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
25 1,598
src/main/java/com/bookssmp/BooksSMP.java
package com.bookssmp;

import com.bookssmp.commands.BookSMPCommand;
import com.bookssmp.commands.SMPCommand;
import com.bookssmp.inventory.gui.GUIListener;
import com.bookssmp.inventory.gui.GUIManager;
import com.bookssmp.listeners.BookProtectionListener;
import com.bookssmp.listeners.BookUseListener;
import com.bookssmp.listeners.PlayerDeathListener;
import com.bookssmp.listeners.PlayerJoinListener;
import com.bookssmp.managers.*;
import lombok.Getter;
import org.bukkit.Bukkit;
import org.bukkit.plugin.java.JavaPlugin;

@Getter
public class BooksSMP extends JavaPlugin {
    private BookManager bookManager;
    private BossBarManager bossBarManager;
    private CountdownManager countdownManager;
    private KillTracker killTracker;
    private DataManager dataManager;
    private GUIManager guiManager;
    private boolean smpStarted;

    @Override
    public void onEnable() {
        saveDefaultConfig();
        this.dataManager = new DataManager(this);
        this.bookManager = new BookManager(this);
        this.bossBarManager = new BossBarManager(this);
        this.countdownManager = new CountdownManager(this);
        this.killTracker = new KillTracker(this);
        this.guiManager = new GUIManager();
        
        this.dataManager.load();
        
        getCommand("smp").setExecutor(new SMPCommand(this));
        getCommand("booksmp").setExecutor(new BookSMPCommand(this));
        
        Bukkit.getPluginManager().registerEvents(new BookUseListener(this), this);
        Bukkit.getPluginManager().registerEvents(new BookProtectionListener(this), this);
        Bukkit.getPluginManager().registerEvents(new PlayerDeathListener(this), this);
        Bukkit.getPluginManager().registerEvents(new PlayerJoinListener(this), this);
        Bukkit.getPluginManager().registerEvents(new GUIListener(guiManager), this);
        
        getLogger().info("BooksSMP has been enabled!");
    }

    @Override
    public void onDisable() {
        if (this.countdownManager != null) {
            this.countdownManager.cancelCountdown();
        }
        if (this.dataManager != null) {
            this.dataManager.save();
        }
        if (this.bossBarManager != null) {
            this.bossBarManager.removeAll();
        }
        getLogger().info("BooksSMP has been disabled!");
    }

    public void setSmpStarted(boolean started) {
        this.smpStarted = started;
    }
}