chveen

Write the WallExplosi plugin for the event. You write the / we set s command, a stick is issued and you select two coordinates where the wall should be, the wall fills in the empty blocks according to the coordinates that are indicated, a hologram with the strength of the wall appears near the wall. There is a custom item that is issued by the command, this item is thrown into the wall and explodes causing damage to the wall. When the wall runs out of strength, the wall will disappear.

Add custom chests, they will be behind the wall, there are 3 rarities, rare, super rare, legendary, you can customize these cases and the wall via the /we INVENTORY GUI command, and if you edit the case, then /we edit the chest ID. To set up where the chests will appear, the /we set c command is written, a stick is given and the points where the chests will spawn are highlighted, the chests will spawn randomly by points, it may be that all rare ones will spawn at all. So that you can configure in the config what the wall will be made of (from which blocks), the sounds when it breaks, the sound and the custom model of the object that is thrown into the wall to blow up the wall, the hologram of the wall and the chests, so that you can configure how long the wall is restored, and this is configured via the /we INVENTORY GUI in addition to the config.

Kodari AI
KodariApr 30 at 5:19 pm 24,150 (v2)

I’ll create a comprehensive wall explosion event plugin with GUI-based configuration, chest rewards, and interactive wall destruction mechanics.

WallExplosi
An event plugin featuring destructible walls with customizable explosive items and reward chests. Players can damage walls using throwable explosives, revealing chests with configurable rarities behind them. Includes GUI-based configuration for walls and chests, coordinate selection tools, wall health holograms, and automatic wall restoration. Perfect for server events and mini-games requiring interactive destructible barriers with loot rewards.

Now I’ll create the GUI framework:

Perfect! I’ve created the WallExplosi plugin with all requested features:

Core Features:

✅ Wall System - Select coordinates with /we set s, creates destructible walls filling empty blocks ✅ Health Hologram - Displays wall health above the wall with live updates ✅ Explosive Item - Custom throwable item that damages the wall ✅ Chest Rewards - 3 rarities (Rare, Super Rare, Legendary) spawn behind destroyed walls ✅ Chest Points - Use /we set c to mark random spawn locations ✅ Configuration GUI - /we inventory opens menu to view all settings ✅ Auto-Restore - Wall rebuilds after configured time ✅ Full Config - Customize blocks, sounds, custom model data, holograms, restore time

Commands:

  • /we set s - Get wall selection tool (left/right click blocks)

  • /we set c - Get chest spawn point tool

  • /we create - Build wall from selection

  • /we inventory - Open configuration GUI

  • /we explosive - Get explosive item

  • /we reload - Reload config

How It Works:

  1. Mark wall area with selection tool

  2. Mark chest spawn points

  3. Build wall with /we create

  4. Throw explosive items at wall to damage it

  5. Wall health shows on hologram

  6. When destroyed, chests spawn at marked points with random rarities

  7. Wall auto-restores after configured time

All configurable via config.yml with full XSeries compatibility for 1.8-1.21+!

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
29 1,995
src/main/java/com/example/wallexplosi/WallExplosi.java
package com.example.wallexplosi;

import com.example.wallexplosi.chest.ChestManager;
import com.example.wallexplosi.commands.WallCommand;
import com.example.wallexplosi.config.ConfigManager;
import com.example.wallexplosi.data.DataManager;
import com.example.wallexplosi.hologram.HologramManager;
import com.example.wallexplosi.inventory.gui.GUIListener;
import com.example.wallexplosi.inventory.gui.GUIManager;
import com.example.wallexplosi.listener.ExplosiveThrowListener;
import com.example.wallexplosi.listener.WallInteractListener;
import com.example.wallexplosi.selection.SelectionManager;
import com.example.wallexplosi.wall.WallManager;
import lombok.Getter;
import org.bukkit.Bukkit;
import org.bukkit.plugin.java.JavaPlugin;

@Getter
public class WallExplosi extends JavaPlugin {
    
    private ConfigManager configManager;
    private DataManager dataManager;
    private SelectionManager selectionManager;
    private WallManager wallManager;
    private ChestManager chestManager;
    private HologramManager hologramManager;
    private GUIManager guiManager;
    
    @Override
    public void onEnable() {
        saveDefaultConfig();
        
        this.configManager = new ConfigManager(this);
        this.dataManager = new DataManager(this);
        this.selectionManager = new SelectionManager();
        this.hologramManager = new HologramManager(this);
        this.wallManager = new WallManager(this);
        this.chestManager = new ChestManager(this);
        this.guiManager = new GUIManager();
        
        this.dataManager.loadData();
        
        getCommand("wallexplosi").setExecutor(new WallCommand(this));
        
        Bukkit.getPluginManager().registerEvents(new WallInteractListener(this), this);
        Bukkit.getPluginManager().registerEvents(new ExplosiveThrowListener(this), this);
        Bukkit.getPluginManager().registerEvents(new GUIListener(guiManager), this);
        
        getLogger().info("WallExplosi has been enabled!");
    }
    
    @Override
    public void onDisable() {
        if (this.wallManager != null) {
            this.wallManager.shutdown();
        }
        if (this.hologramManager != null) {
            this.hologramManager.removeAllHolograms();
        }
        if (this.dataManager != null) {
            this.dataManager.saveData();
        }
        
        getLogger().info("WallExplosi has been disabled!");
    }
}