sohail0580

Create a Minecraft 1.21.1 Paper/Spigot plugin with the following mechanics:

CORE MECHANIC:

* When a player breaks ANY block, ALL blocks of the SAME type within a 20-block radius automatically break instantly. * Blocks do NOT need to be connected. * The plugin should scan the entire radius area and destroy every matching block type.

EXAMPLES:

* Break 1 grass block → all grass blocks within 20 blocks break. * Break 1 stone block → all nearby stone blocks within 20 blocks break. * Break 1 oak log → all nearby oak logs within 20 blocks break.

IMPORTANT:

* This is NOT vein mining. * Radius-based mass destruction system only.

OP LOOT SYSTEM:

Every broken block from the chain reaction should have chances to drop random overpowered loot.

COMMON OP LOOT:

* Diamonds * Emeralds * Golden apples * XP bottles * TNT * Iron blocks * Gold blocks

RARE LOOT:

* Netherite ingots * Enchanted golden apples * Totems of undying * Elytra * Beacons * Ancient debris

LEGENDARY CUSTOM ITEMS:

Create custom overpowered items with custom names, lore, glowing effects, and enchantments beyond vanilla limits.

Examples:

  1. Jungle Destroyer

* Netherite Sword * Sharpness 10 * Fire Aspect 5 * Looting 10

  1. God Miner

* Netherite Pickaxe * Efficiency 10 * Fortune 10 * Unbreaking 10

  1. Titan Armor Set

* Protection 10 * Thorns 5 * Feather Falling 10 * Soul Speed 5

  1. Dragon Hunter Bow

* Power 10 * Infinity * Flame 5

CHAOS EVENTS:

Random chance during chain destruction to trigger:

* Lightning strikes * Small explosions * Treasure rain * Random hostile mob spawns * Speed boost * Strength boost

VISUAL EFFECTS:

* Particle effects while blocks break * Rare item glow effects * Cinematic sounds * Big reward title popups

CONFIG OPTIONS:

* radius * max-blocks * loot chances * legendary loot rarity * enable-particles * enable-sounds * cooldown * whitelist * blacklist

PERFORMANCE:

* Optimized for Paper 1.21.1 * Prevent TPS drops * Batch process blocks * Prevent infinite recursion * Multiplayer compatible

GOAL:

The gameplay should feel extremely chaotic, satisfying, cinematic, and overpowered, where breaking a single block destroys nearby matching blocks and creates explosions of OP loot perfect for Minecraft YouTube challenge videos.

Kodari AI
KodariMay 15 at 10:55 am 17,053 (v2)

I’ll plan this out carefully before writing any code.

Plan:

  • RadiusDestroyPlugin - main plugin class with managers

  • ConfigManager - all config values

  • LootManager - common/rare/legendary loot generation

  • ChainDestroyManager - radius scan, batch block breaking, performance guards

  • ChaosEventManager - lightning, explosions, mob spawns, potion effects

  • EffectsManager - particles, sounds, titles

  • ChainDestroyListener - BlockBreakEvent handler

  • GUI framework (InventoryHandler, InventoryButton, InventoryGUI, GUIManager, GUIListener)

  • AdminGUI - in-game config editor

  • AdminCommand - /rdestroy command

RadiusDestroy
A chaotic, overpowered Minecraft plugin where breaking any block instantly destroys all matching blocks within a configurable radius. Features an OP loot system with common, rare, and legendary custom items, random chaos events (lightning, explosions, mob spawns, potion boosts), cinematic particle/sound effects, and title popups. Fully configurable via config.yml and an in-game admin GUI. Optimized for Paper 1.21.1 with batch processing and TPS protection.

Here’s a summary of everything built:

Core System:

  • ChainDestroyManager — scans a sphere of radius R for matching block types, batch-processes them in configurable tick-delayed chunks to prevent TPS drops, and guards against cooldowns and blacklisted blocks

  • ChainDestroyListener — hooks BlockBreakEvent at MONITOR priority so it fires after other plugins cancel/modify the event

Loot System (LootManager):

  • Common pool: diamonds, emeralds, golden apples, XP bottles, TNT, iron/gold blocks

  • Rare pool: netherite ingots, enchanted golden apples, totems, elytra, beacons, ancient debris

  • Legendary pool: 5 custom items (Jungle Destroyer, God Miner, Dragon Hunter Bow, Titan Helmet, Titan Chestplate) with enchants beyond vanilla limits via XEnchantment

Chaos Events (ChaosEventManager): Lightning strikes, small explosions, treasure rain (5 bonus loot drops), hostile mob spawns, Speed IV boost, Strength III boost — each with title popups and sounds

Effects (EffectsManager): Per-block FLAME + SMOKE particles, chain-start EXPLOSION + CRIT_MAGIC burst, legendary TOTEM + END_ROD shower, cinematic sounds, and title popups for chain count, legendary drops, and chaos events

Admin GUI (AdminGUI): 54-slot bordered panel with click-to-adjust buttons for radius, max-blocks, cooldown, particles toggle, and all four loot/chaos chances — changes save to config.yml instantly

/rdestroy command: Opens GUI, reloads config, or prints current settings — requires radiusdestroy.admin (default: op)

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
17 1,289
src/main/java/com/radiusdestroy/RadiusDestroyPlugin.java
package com.radiusdestroy;

import com.radiusdestroy.command.AdminCommand;
import com.radiusdestroy.inventory.gui.GUIListener;
import com.radiusdestroy.inventory.gui.GUIManager;
import com.radiusdestroy.listener.ChainDestroyListener;
import com.radiusdestroy.manager.ChainDestroyManager;
import com.radiusdestroy.manager.ChaosEventManager;
import com.radiusdestroy.manager.ConfigManager;
import com.radiusdestroy.manager.EffectsManager;
import com.radiusdestroy.manager.LootManager;
import lombok.Getter;
import org.bukkit.plugin.java.JavaPlugin;

public class RadiusDestroyPlugin extends JavaPlugin {

    @Getter private ConfigManager configManager;
    @Getter private LootManager lootManager;
    @Getter private EffectsManager effectsManager;
    @Getter private ChaosEventManager chaosEventManager;
    @Getter private ChainDestroyManager chainDestroyManager;
    @Getter private GUIManager guiManager;

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

        configManager = new ConfigManager(this);
        lootManager = new LootManager(this);
        effectsManager = new EffectsManager(this);
        chaosEventManager = new ChaosEventManager(this);
        chainDestroyManager = new ChainDestroyManager(this);
        guiManager = new GUIManager();

        getServer().getPluginManager().registerEvents(new ChainDestroyListener(this), this);
        getServer().getPluginManager().registerEvents(new GUIListener(guiManager), this);

        AdminCommand adminCommand = new AdminCommand(this);
        getCommand("rdestroy").setExecutor(adminCommand);
        getCommand("rdestroy").setTabCompleter(adminCommand);

        getLogger().info("RadiusDestroy enabled! Chaos awaits.");
    }

    @Override
    public void onDisable() {
        getLogger().info("RadiusDestroy disabled.");
    }
}