melissa121gg

so i want a plugin that u can do /choose event and it opens a INVENTORY GUI the size of a normal shulkerbox and in that INVENTORY GUI make put a mace with the name juggernaut and a normal diamond sword with name ffa and a campfire with name teams make it so the items cant be taken out and only clicked on and choosen afterwards make it so only people with the op permission can see how many votes each option got like if juggernaut got choosen 5 times make it show that and the same for each option no matter the votes show how many there are and make it everyone can choose it one times and make it so op users and edit the the inside of the INVENTORY GUI and place where the option to choose for a gamemode is like which slots and make each slot a green glass pane only the ones with the abilty to vote

Kodari AI
KodariMar 21 at 10:27 pm 15,106 (v2)

I’ll create a voting system plugin with a customizable GUI for event selection.

EventChooser
An interactive voting system that allows players to choose between event types through a GUI. Features three customizable event options with vote tracking, one-vote-per-player limitation, operator vote count visibility, and admin edit mode for repositioning vote options in the interface.

All files created! The EventChooser plugin is ready with:

  • Voting GUI (/choose event) - 27-slot inventory with 3 vote options (Juggernaut/Mace, FFA/Diamond Sword, Teams/Campfire)

  • Edit Mode (/choose event edit) - OPs can drag items to reposition vote options

  • Vote Tracking - One vote per player, vote counts visible only to OPs

  • Green Glass Pane - Fills empty slots in voting GUI

  • Cross-Version Support - Uses XSeries with fallback materials (Mace → Diamond Axe for older versions)

The plugin automatically saves vote data and player positions to config.yml.

melissa121gg

can u add xseries to it

Kodari AI
KodariMar 21 at 10:32 pm 10,171 (v2)

I’ll read the existing files to see what needs to be updated with XSeries patterns.

I can see XSeries is already imported and used in your GUI files. Let me update the code to use XSeries patterns more consistently, particularly fixing the direct enum access for the glass pane decoration.

XSeries is now properly integrated throughout your plugin with consistent usage patterns:

  • Material matching uses XMaterial.matchXMaterial() for cross-version compatibility (1.8-1.21+)

  • All GUI items are created through XSeries with proper fallback handling

  • Glass pane decoration now uses the recommended pattern instead of direct enum access

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
14 697
src/main/java/com/eventchooser/EventChooser.java
package com.eventchooser;

import com.eventchooser.command.ChooseCommand;
import com.eventchooser.inventory.gui.GUIListener;
import com.eventchooser.inventory.gui.GUIManager;
import com.eventchooser.manager.VoteManager;
import lombok.Getter;
import org.bukkit.Bukkit;
import org.bukkit.plugin.java.JavaPlugin;

@Getter
public class EventChooser extends JavaPlugin {
    private GUIManager guiManager;
    private VoteManager voteManager;

    @Override
    public void onEnable() {
        saveDefaultConfig();
        
        this.voteManager = new VoteManager(this);
        this.voteManager.load();
        
        this.guiManager = new GUIManager();
        
        Bukkit.getPluginManager().registerEvents(new GUIListener(guiManager), this);
        
        getCommand("choose").setExecutor(new ChooseCommand(this));
        
        getLogger().info("EventChooser has been enabled!");
    }

    @Override
    public void onDisable() {
        if (voteManager != null) {
            voteManager.save();
        }
        getLogger().info("EventChooser has been disabled!");
    }
}