mehediwastaken

make a plugin minecraft plugin name is rtpBD when a player use /rtpbd it will auto teleport them to 5000 blocks away it will work goodly and command cooldown is 60 seconds it will help player by /help comand make now

Kodari AI
KodariJul 27 at 8:10 am 1

I’ll create the RTPBD plugin — a random teleport plugin with a 60s cooldown and a custom help command.

RTPBD
A random teleport plugin that teleports players 5000 blocks away from spawn with a single command. Features include a configurable cooldown system (default 60 seconds), safe location detection using highest block Y, and a custom help command showing plugin information. Supports configurable radius and cooldown through config.yml for easy server administration.</project_descriptionI'll create the **rtpBD** plugin — a random teleport plugin with a 60s cooldown and a built-in help command.
RtpBD
Random teleport plugin that teleports players 5000 blocks away with a single command. Features a 60-second cooldown, safe landing detection, and a built-in help system via /help and /rtpbd help. Lightweight and ready to use with configurable cooldown and radius.

Now I’ll create all the files

Now I’ll create the entire RTPBD plugin from scratch.

A random teleport plugin for Minecraft. Players use /rtpbd to teleport to a random location up to 5000 blocks away from origin. Features a 60-second cooldown per player, configurable teleport distance and cooldown, safe landing detection (teleports to the highest solid block), and a built-in /help command that shows plugin usage instructions.

Let me build the complete plugin structure — all files at once.

All files created. Here’s the plugin structure:

File
Purpose
RTPBD.java
Main plugin — registers commands, creates managers
CooldownManager.java
Tracks per-player cooldown (60s default)
TeleportManager.java
Random location generation, warmup, safe teleport
RTPCommand.java
/rtpbd
command — triggers teleport,
/rtpbd help
shows help
HelpCommand.java
/help
command — shows help (also accessible via
/rtpbdhelp
)
config.yml
All configurable: distance, cooldown, warmup, messages
plugin.yml
Command registration and metadata

How it works:

  1. Player runs /rtpbd → warmup countdown starts (3s by default, cancel if they move)

  2. After warmup → random X/Z between -5000 and 5000, teleports to highest solid block +1

  3. 60s cooldown applied per player — message shows remaining time if they try again

  4. /help or /rtpbd help shows the help menu

  5. Everything is configurable in config.yml — distance, cooldown, warmup, messages

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
settings.gradle
Code
9 345
src/main/java/com/rtpbd/RTPBD.java
package com.rtpbd;

import com.rtpbd.commands.HelpCommand;
import com.rtpbd.commands.RTPCommand;
import com.rtpbd.managers.CooldownManager;
import com.rtpbd.managers.TeleportManager;
import org.bukkit.plugin.java.JavaPlugin;

public class RTPBD extends JavaPlugin {

    private CooldownManager cooldownManager;
    private TeleportManager teleportManager;

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

        this.cooldownManager = new CooldownManager(this);
        this.teleportManager = new TeleportManager(this, cooldownManager);

        getCommand("rtpbd").setExecutor(new RTPCommand(this, teleportManager, cooldownManager));
        getCommand("rtpbdhelp").setExecutor(new HelpCommand(this));

        getLogger().info("RTPBD has been enabled!");
    }

    @Override
    public void onDisable() {
        getLogger().info("RTPBD has been disabled!");
    }

    public CooldownManager getCooldownManager() {
        return cooldownManager;
    }

    public TeleportManager getTeleportManager() {
        return teleportManager;
    }
}