Rayan

make plugin clean enitity every 5m and add clean entity command and shows commands like /clearenity clear cooldown and the cooldown like i can add cooldown and add the block like /cleanentity add block and add every block in the game and when its gonna clean the enitiy lety it type in chat clear map in 10 9 8 7 ... you know and every minute add like 5 minute after 1 minute 4 minute ok

Kodari AI
KodariSep 30 at 1:29 pm 1
EntityPurgeScheduler
A Minecraft plugin that automatically cleans all entities every 5 minutes with a countdown announcement in chat. Features a /cleanentity command system with configurable cooldowns, allowing admins to set custom intervals between cleanups. Includes a block management system where specific blocks can be added to protect entities standing on them from being removed. The plugin announces cleanup timers in chat, displaying countdowns like "10, 9, 8..." before each purge, and shows minute-by-minute updates (5 minutes, 4 minutes, etc.) leading up to the cleanup. Provides full control over which entities are affected and when cleanups occur.
  1. Create the Paper plugin scaffold and default five-minute cleanup configuration.

  2. Add scheduled countdown announcements, entity cleanup, protected-block management, and /cleanentity commands with /clearenity alias.

Created the CleanEntity plugin with a five-minute automatic cleanup cycle and countdown announcements at each minute and during the final 10 seconds. /cleanentity and /clearenity support manual cleanup, cooldown changes, countdown reset, and adding, removing, or listing protected blocks. Entities standing on protected blocks are kept; players are never removed.

Rayan

did you do all of it i say

Kodari AI
KodariSep 30 at 1:30 pm 1

Mostly. The plugin has:

  • Automatic cleanup every 5 minutes, with minute-by-minute announcements and a final 10-second countdown.

  • /clearenity as an alias for /cleanentity.

  • /cleanentity clear cooldown to restart the countdown, and /cleanentity cooldown <minutes> to change the interval.

  • /cleanentity add block <block> and /cleanentity remove block <block> to manage protected blocks.

One detail wasn’t fully covered: you can enter any block name available on your server, but the command doesn’t list every block in tab-completion or add all blocks at once.

Rayan

did you do when i do /cleearentity show all commands

Kodari AI
KodariSep 30 at 1:31 pm 1

Yes—/cleanentity with no arguments shows the command list. I’ve also added /cleearentity as an alias, so that spelling shows the same help.

Rayan

ok can you also add like blocks clean like if i put cobweb after 1 m clean up pls

Kodari AI
KodariSep 30 at 2:13 pm 1
  1. Add configurable per-block lifetimes that start when a player places the block.

  2. Add commands to set, remove, and list timed-cleanup blocks; accept durations like 1m.

Added timed cleanup for newly placed blocks. Configure cobwebs to disappear after one minute with:

/cleanentity add cleanupblock COBWEB 1m

You can also use a number of minutes, e.g. 2. Use /cleanentity list cleanupblocks to view rules, or /cleanentity remove cleanupblock COBWEB to remove one. The rules save across restarts, but timers for blocks already placed don’t persist through a restart.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
settings.gradle
Code
7 491
src/main/java/com/kodari/cleanentity/CleanEntityPlugin.java
package com.kodari.cleanentity;

import org.bukkit.plugin.java.JavaPlugin;

public final class CleanEntityPlugin extends JavaPlugin {
    private CleanupManager cleanupManager;

    @Override
    public void onEnable() {
        saveDefaultConfig();
        cleanupManager = new CleanupManager(this);
        getServer().getPluginManager().registerEvents(cleanupManager, this);
        cleanupManager.start();

        CleanEntityCommand command = new CleanEntityCommand(this, cleanupManager);
        getCommand("cleanentity").setExecutor(command);
        getCommand("cleanentity").setTabCompleter(command);
    }

    @Override
    public void onDisable() {
        if (cleanupManager != null) {
            cleanupManager.stop();
        }
    }
}