yashgamer7736.

CREATE A COMPLETE, BUILDABLE MINECRAFT PAPER PLUGIN CALLED "RelicSMP".

DO NOT GIVE ME A TUTORIAL.

DO NOT GIVE ME PSEUDOCODE.

DO NOT GIVE ME PARTIAL CODE.

I want the COMPLETE source project with all Java files, plugin.yml, config.yml, pom.xml and all required files so I can compile it into a working .jar.

================================================== BASIC INFORMATION ==================================================

Plugin name:

RelicSMP

Minecraft:

Paper 1.21.x

Java:

Java 21

Main package: com.godgamer16.relicsmp

Target server size: 8–10 players

================================================== CORE RELIC SYSTEM ==================================================

There are EXACTLY 10 Relics:

  1. GRAVITY
  2. STORM
  3. INFERNO
  4. SHADOW
  5. FROST
  6. NATURE
  7. STRENGTH
  8. VOID
  9. WIND
  10. GUARDIAN

IMPORTANT:

DO NOT include a Time Relic.

There must be exactly these 10 Relics and no extra Relics.

================================================== RELIC ITEM DESIGN ==================================================

IMPORTANT:

DO NOT use blocks as Relics.

Do NOT use:

  • Stained Glass
  • Glass
  • Blocks
  • Ores
  • Obsidian blocks
  • Any other block

All 10 Relics must be ITEM-type objects.

I want all Relics to use the SAME CATEGORY/TYPE of item: DYE.

Use different coloured Minecraft dye items for the 10 Relics.

Use these:

GRAVITY:

PURPLE_DYE

STORM:

CYAN_DYE

INFERNO:

RED_DYE

SHADOW:

BLACK_DYE

FROST:

LIGHT_BLUE_DYE

NATURE:

GREEN_DYE

STRENGTH:

ORANGE_DYE

VOID:

MAGENTA_DYE

WIND:

WHITE_DYE

GUARDIAN:

YELLOW_DYE

The physical appearance should therefore immediately communicate that the Relics are the same kind of item but have different colours.

IMPORTANT:

Do NOT identify Relics only using the material.

Use PersistentDataContainer with a unique Relic ID.

For example:

GRAVITY STORM INFERNO SHADOW FROST NATURE STRENGTH VOID WIND GUARDIAN

This prevents a normal Purple Dye from being treated as the Gravity Relic.

================================================== RELIC NAMES ==================================================

Give each item a custom display name.

Examples:

§5§lGRAVITY RELIC §b§lSTORM RELIC §c§lINFERNO RELIC §8§lSHADOW RELIC §9§lFROST RELIC §a§lNATURE RELIC §6§lSTRENGTH RELIC §5§lVOID RELIC §f§lWIND RELIC §e§lGUARDIAN RELIC

Use modern Adventure/MiniMessage or another safe Paper-compatible method if appropriate.

Each Relic must have useful lore explaining:

  • What the Relic does
  • How to activate it
  • Its cooldown

Example:

GRAVITY RELIC

"Source of Gravity Power"

"Hold this Relic and RIGHT CLICK"

"to activate its ability."

"Cooldown: 40 seconds"

================================================== IMPORTANT HOLDING MECHANIC ==================================================

The physical Relic itself is the SOURCE OF THE POWER.

A player can use the ability ONLY while physically holding the correct Relic.

Holding means:

MAIN HAND OR OFF HAND

If the Relic is:

  • somewhere else in inventory
  • inside a chest
  • inside an Ender Chest
  • inside a shulker box
  • dropped on the ground

the player cannot activate the ability.

The plugin must check the actual item in the player's main hand and off-hand.

Do NOT simply check whether the player owns the Relic in their saved data.

================================================== ACTIVATION ==================================================

Right-click while holding a Relic.

Use:

RIGHT_CLICK_AIR or RIGHT_CLICK_BLOCK

to activate.

The plugin must:

  1. Check whether the player is holding a valid Relic.
  2. Identify its PDC Relic ID.
  3. Check its cooldown.
  4. If cooldown is ready, activate the ability.
  5. Start the cooldown only after successful activation.

================================================== 10 RELICS AND POWERS ==================================================

==================================================

  1. GRAVITY RELIC

==================================================

Item:

PURPLE_DYE

Cooldown: 40 seconds

Power:

When activated:

PHASE 1:

Create gravity particles around the player.

PHASE 2:

For approximately 1.5 seconds, nearby enemies within about 8 blocks are gradually pulled toward the player.

PHASE 3:

After the pull finishes, create a powerful gravity burst.

The burst should knock nearby enemies away.

The player using the Gravity Relic must NOT be pulled by their own ability.

The ability should feel like:

PULL → CHARGE → BURST

Do not instantly kill players.

Do not permanently modify terrain.

Use appropriate particles and sounds.

==================================================

  1. STORM RELIC

==================================================

Item:

CYAN_DYE

Cooldown: 35 seconds

Power:

When activated:

  • Find the block the player is looking at within 30 blocks.
  • Call lightning at the target location.
  • Create electric particles.
  • Play an appropriate thunder/lightning sound.

Do not repeatedly strike lightning.

==================================================

  1. INFERNO RELIC

==================================================

Item:

RED_DYE

Cooldown: 30 seconds

Power:

When activated:

  • Launch a fireball in the direction the player is looking.
  • Fireball can damage enemies.
  • Explosion should be controlled.
  • Do not create uncontrollable permanent fire everywhere.
  • Use flame particles.
  • Play an appropriate fire sound.

==================================================

  1. SHADOW RELIC

==================================================

Item:

BLACK_DYE

Cooldown: 40 seconds

Power:

When activated:

  • Give temporary invisibility.
  • Blink/teleport the player forward.
  • Teleport must never place the player inside a solid block.
  • Use smoke/dark particles.
  • Play a shadow-like sound.

==================================================

  1. FROST RELIC

==================================================

Item:

LIGHT_BLUE_DYE

Cooldown: 35 seconds

Power:

When activated:

  • Affect enemies within approximately 7 blocks.
  • Apply strong Slowness temporarily.
  • Optionally apply Mining Fatigue.
  • Create snow/ice particles.
  • Play a freezing sound.

Do not permanently destroy or modify terrain.

==================================================

  1. NATURE RELIC

==================================================

Item:

GREEN_DYE

Cooldown: 45 seconds

Power:

When activated:

  • Give temporary Regeneration.
  • Give temporary Resistance.
  • Create nature/green particles.
  • Play a nature sound.

==================================================

  1. STRENGTH RELIC

==================================================

Item:

ORANGE_DYE

Cooldown: 40 seconds

Power:

When activated:

  • Give temporary Strength.
  • Give a small amount of Resistance.
  • Create a power-up effect.
  • Play an appropriate sound.

==================================================

  1. VOID RELIC

==================================================

Item:

MAGENTA_DYE

Cooldown: 45 seconds

Power:

When activated:

  • Blink/teleport the player forward.
  • Never teleport inside solid blocks.
  • Knock nearby enemies away.
  • Create dark/void particles.
  • Play an appropriate void sound.

==================================================

  1. WIND RELIC

==================================================

Item:

WHITE_DYE

Cooldown: 25 seconds

Power:

When activated:

  • Launch the player forward.
  • Give a controlled upward boost.
  • Create wind particles.
  • Play an appropriate wind sound.

Do not launch the player hundreds of blocks away.

==================================================

  1. GUARDIAN RELIC

==================================================

Item:

YELLOW_DYE

Cooldown: 50 seconds

Power:

When activated:

  • Give strong temporary Resistance.
  • Give temporary Absorption.
  • Create defensive particles.
  • Play an appropriate guardian/shield sound.

================================================== COOLDOWN SYSTEM ==================================================

FINAL COOLDOWNS:

GRAVITY = 40 seconds STORM = 35 seconds INFERNO = 30 seconds SHADOW = 40 seconds FROST = 35 seconds NATURE = 45 seconds STRENGTH = 40 seconds VOID = 45 seconds WIND = 25 seconds GUARDIAN = 50 seconds

Every Relic has an independent cooldown.

Cooldown begins ONLY after successful activation.

If the player tries to activate while cooling down:

DO NOT activate the ability.

Show an ActionBar such as:

"Relic Cooldown: 24s"

The remaining time must be accurate.

================================================== CONFIGURABLE COOLDOWNS ==================================================

Put cooldown values in config.yml:

cooldowns:

GRAVITY: 40 STORM: 35 INFERNO: 30 SHADOW: 40 FROST: 35 NATURE: 45 STRENGTH: 40 VOID: 45 WIND: 25 GUARDIAN: 50

The plugin must read cooldowns from config.yml rather than hard-coding them.

Also make reasonable ability ranges/durations configurable where practical.

================================================== ONE-TIME RANDOM ROLL ==================================================

Players receive their Relic using:

/relic roll

A player can use this command ONLY ONCE.

After rolling:

  • Save their UUID.
  • Save their assigned Relic.
  • Give them the physical Relic item.

If they leave the server and return:

They still have the same assigned Relic.

If the server restarts:

They still have the same assigned Relic.

If the plugin reloads:

They still have the same assigned Relic.

================================================== UNIQUE RELICS ==================================================

Normal random rolls must NOT duplicate Relics.

Example:

Player 1 gets GRAVITY.

Player 2 cannot get GRAVITY.

Player 3 cannot get GRAVITY.

Every new roll selects randomly from the remaining unassigned Relics.

Each remaining Relic has an equal chance.

If all 10 Relics are already assigned:

/relic roll

must return a message such as:

"All Relics have already been assigned."

Do NOT create a duplicate.

================================================== RELIC STEALING ==================================================

This is VERY IMPORTANT for the SMP.

The physical Relic item can be stolen.

Example:

Player A has the Storm Relic.

Player A dies.

The Storm Relic drops naturally.

Player B picks it up.

Player B holds the Storm Relic.

Player B can now use the Storm power.

The saved roll assignment of Player A remains in the database.

Do NOT automatically create another Storm Relic.

The physical item is the source of the power.

================================================== DEATH SYSTEM ==================================================

Do NOT create duplicate Relics after death.

If the player dies while the physical Relic is in their inventory:

Let Minecraft drop the item naturally.

If the player was not carrying the physical Relic:

Do not create a replacement.

================================================== ANTI-DUPLICATION ==================================================

Prevent easy duplication of Relics.

Do NOT give another Relic when:

  • player rejoins
  • server restarts
  • player changes worlds
  • player dies
  • inventory changes
  • plugin reloads

Only create physical Relics through:

/relic roll

or:

/relic give

================================================== COMMANDS ==================================================

PLAYER COMMANDS:

/relic roll

Randomly assigns one unassigned Relic.

/relic info

Shows the player's assigned Relic and its ability.

/relic list

Shows all 10 Relics and their abilities.

================================================== ADMIN COMMANDS ==================================================

Permission:

relicsmp.admin

Commands:

/relic give <player> <relic>

/relic reset <player>

/relic reload

/relic info <player>

Admin /relic give:

  • Assign the selected Relic to the player.
  • Give the physical Relic.
  • Save the assignment.

Admin /relic reset:

  • Remove the player's saved assignment.
  • Allow the player to use /relic roll again.

Admin /relic reload:

  • Reload config.yml.

================================================== DATA STORAGE ==================================================

Use:

plugins/RelicSMP/players.yml

Store data using UUID.

Example:

UUID: relic: GRAVITY rolled: true

Save immediately after:

  • player rolls
  • admin gives Relic
  • admin resets player
  • plugin disables

================================================== RELIC ITEM SECURITY ==================================================

Use PersistentDataContainer.

Every physical Relic must have:

relic_id = GRAVITY

or:

relic_id = STORM

etc.

A normal:

PURPLE_DYE

must NOT activate Gravity.

Only the plugin-generated Purple Dye with the correct PDC can activate Gravity.

If a player renames normal Purple Dye to:

GRAVITY RELIC

it must NOT work.

================================================== VISUAL EFFECTS ==================================================

Give each Relic a unique visual identity.

Use only vanilla Minecraft features:

  • particles
  • sounds
  • potion effects
  • velocity
  • projectiles
  • lightning
  • safe teleportation

Do NOT require:

  • mods
  • client-side plugins
  • resource packs
  • external software

================================================== COMMAND TAB COMPLETION ==================================================

Implement tab completion for:

/relic roll /relic info /relic list /relic give <player> <relic> /relic reset <player> /relic reload

Relic names must autocomplete.

================================================== EDGE CASES ==================================================

Handle all of these safely:

  • Player disconnects during ability cooldown.
  • Player disconnects during Gravity ability.
  • Server restarts.
  • Plugin reloads.
  • Player changes worlds.
  • Player dies.
  • Player puts Relic into chest.
  • Player puts Relic into Ender Chest.
  • Player puts Relic into shulker box.
  • Player holds Relic in off-hand.
  • Player holds Relic in main hand.
  • Player has multiple Relic items.
  • Player has fake dye with same name.
  • Invalid player.
  • Invalid Relic name.
  • Player attempts second roll.
  • All Relics assigned.
  • Admin gives Relic.
  • Admin resets Relic.
  • Two players attempt /relic roll nearly simultaneously.

Do not crash the server.

Do not spam console with unnecessary errors.

================================================== PERFORMANCE ==================================================

The server normally has only 8–10 players.

Still:

  • Avoid unnecessary repeating tasks.
  • Do not scan every entity every tick.
  • Use scheduled tasks only where necessary.
  • Cancel temporary tasks when finished.
  • Avoid memory leaks.
  • Keep the plugin lightweight.

================================================== PROJECT STRUCTURE ==================================================

Create a proper Maven project.

Recommended:

RelicSMP/ │ ├── pom.xml │ └── src/ └── main/ ├── java/ │ └── com/ │ └── godgamer16/ │ └── relicsmp/ │ ├── RelicSMP.java │ ├── Relic.java │ ├── RelicManager.java │ ├── CooldownManager.java │ ├── DataManager.java │ ├── RelicCommand.java │ ├── RelicListener.java │ └── AbilityManager.java │ └── resources/ ├── plugin.yml └── config.yml

You may change the class structure if you have a cleaner architecture.

================================================== PAPER / JAVA REQUIREMENTS ==================================================

Use:

Java 21

Paper 1.21.x API

Maven

Make sure all APIs used actually exist in the selected Paper API version.

Do not leave deprecated or broken method calls.

Make sure:

  • package names match
  • plugin.yml main class matches
  • every import is valid
  • every class compiles
  • every method exists
  • every dependency is declared
  • Maven build succeeds

================================================== PLUGIN.YML ==================================================

Create a correct plugin.yml with:

name: RelicSMP

version: 1.0.0

main: com.godgamer16.relicsmp.RelicSMP

api-version: 1.21

author: godgamer16

command: relic

permission: relicsmp.admin

================================================== FINAL TESTING ==================================================

Before giving me the project, verify these scenarios:

TEST 1:

New player joins.

They use:

/relic roll

They receive exactly one random unassigned Relic.

TEST 2:

They use /relic roll again.

The plugin refuses.

TEST 3:

Server restarts.

Their Relic assignment remains.

TEST 4:

Relic is inside inventory but not held.

Right-click.

Nothing happens.

TEST 5:

Relic is held in main hand.

Right-click.

Power activates.

TEST 6:

Relic is held in off-hand.

Right-click.

Power activates.

TEST 7:

Ability is used.

Player immediately tries again.

Ability does not activate.

Cooldown ActionBar appears.

TEST 8:

Cooldown finishes.

Ability works again.

TEST 9:

Player dies while carrying their Relic.

Relic drops.

Another player picks it up.

They hold it.

They can use that Relic's ability.

TEST 10:

Admin uses:

/relic reset <player>

Player can roll again.

TEST 11:

Admin uses:

/relic give <player> GRAVITY

Player receives the Gravity Relic.

TEST 12:

Two players roll.

They cannot receive the same Relic.

TEST 13:

All 10 Relics are assigned.

Another player tries /relic roll.

They cannot receive a duplicate.

TEST 14:

A player renames normal Purple Dye to "GRAVITY RELIC".

It does NOT activate Gravity.

TEST 15:

Player places their real Relic in a chest.

It cannot activate from the chest.

================================================== FINAL INSTRUCTION ==================================================

DO NOT include the Time Relic.

DO NOT use blocks as Relics.

All 10 Relics must use dye items.

The exact Relic item mapping is:

GRAVITY = PURPLE_DYE STORM = CYAN_DYE INFERNO = RED_DYE SHADOW = BLACK_DYE FROST = LIGHT_BLUE_DYE NATURE = GREEN_DYE STRENGTH = ORANGE_DYE VOID = MAGENTA_DYE WIND = WHITE_DYE GUARDIAN = YELLOW_DYE

There must be exactly 10 Relics.

The physical Relic is the source of the power.

Power works ONLY while the correct physical Relic is held in main hand or off-hand.

Normal player rolls are one-time only.

Normal rolls must produce unique Relics.

Every Relic has its specified cooldown.

Make the COMPLETE BUILDABLE Paper plugin project.

Kodari AI
KodariAug 24 at 7:39 am 3
RelicSMP
RelicSMP is a Minecraft Paper plugin that introduces a unique relic system where players roll for one of ten distinct dye-based relics, each granting a powerful active ability. Relics are physical items that must be held in the main or off-hand to activate their powers, which include gravity manipulation, lightning strikes, fireballs, invisibility, frost effects, healing, strength boosts, void teleportation, wind launching, and defensive shields. The plugin features persistent player data storage, configurable cooldowns, unique relic assignments, and an admin command system for managing relics and player data.
  1. Create the Maven project and Paper plugin metadata.

  2. Implement the exact 10-dye Relic model, secure PDC items, persistence, and unique assignment rules.

  3. Implement cooldowns, command handling/tab completion, listeners, and all ten abilities.

  4. Add configurable cooldowns and ability settings.

Created the complete buildable RelicSMP Maven project.

Included:

  • Paper 1.21.4 API with Java 21

  • Exactly 10 Relics, with no Time Relic

  • Dye-based physical Relic items using secure PDC IDs

  • Unique one-time random assignment system

  • Persistent players.yml storage

  • Admin commands and tab completion

  • Independent configurable cooldowns

  • Main-hand and off-hand activation checks

  • All ten requested abilities

  • Safe teleportation, controlled fireballs, particles, sounds, and potion effects

  • Natural Relic drops and stealing support

  • pom.xml

  • plugin.yml

  • config.yml

  • Complete Java source under com.godgamer16.relicsmp

Kodari can make mistakes. Review important code before using.
Files
src
pom.xml
Code
11 978
src/main/java/com/godgamer16/relicsmp/RelicSMP.java
package com.godgamer16.relicsmp;

import org.bukkit.Bukkit;
import org.bukkit.command.PluginCommand;
import org.bukkit.plugin.java.JavaPlugin;

public class RelicSMP extends JavaPlugin {
    private DataManager dataManager;
    private RelicManager relicManager;
    private CooldownManager cooldownManager;
    private AbilityManager abilityManager;

    @Override
    public void onEnable() {
        saveDefaultConfig();
        relicManager = new RelicManager(this);
        dataManager = new DataManager(this);
        cooldownManager = new CooldownManager(this);
        abilityManager = new AbilityManager(this);

        Bukkit.getPluginManager().registerEvents(
                new RelicListener(relicManager, cooldownManager, abilityManager), this);

        RelicCommand commandHandler = new RelicCommand(this, dataManager, relicManager, cooldownManager);
        PluginCommand command = getCommand("relic");
        if (command != null) {
            command.setExecutor(commandHandler);
            command.setTabCompleter(commandHandler);
        }
    }

    @Override
    public void onDisable() {
        if (dataManager != null) {
            dataManager.save();
        }
        if (cooldownManager != null) {
            cooldownManager.clearAll();
        }
    }
}