E

Add a Magician tag.

Players with the Magician tag always have 9 hearts.

Only Magician players can craft custom magic potions.

Froglight Potion Add a custom crafting recipe using:

Any Froglight Nether Wart Water Bottle Blaze Powder Only players with the Magician tag can craft it.

Drinking it grants Jump Boost III for 3 minutes.

Give it a custom name and lore.

Do not conflict with vanilla recipes.

Kodari AI
KodariJul 22 at 9:27 am 1

I’ll create a MagicianPlugin — a Minecraft plugin that adds a Magician tag with 9 hearts, exclusive Froglight Potion crafting, and custom brewing mechanics.

MagicianPlugin
A Minecraft plugin that introduces the Magician tag system. Players with the Magician tag have 9 hearts instead of the default 10. Only Magicians can craft custom Froglight Potions — a unique brew granting Jump Boost III for 3 minutes. Features configurable tag management via commands, custom crafting recipes using froglights, and full cross-version compatibility through XSeries.
E

Use commands like this /give @a potion[potion_contents={custom_color:8439583,custom_effects:[{id:jump_boost,duration:600,amplifier:2}]}]

Kodari AI
KodariJul 22 at 9:37 am 2

Let me first check what exists.

The plugin exists with the basic structure. The user wants the potion to use the modern component format (matching /give @a potion[potion_contents={...}]). I’ll update the potion creation to use the correct color 8439583 and embed the Jump Boost effect directly in the potion meta (so it applies automatically on drink, matching the component format).

Let me verify the final state

Let me clean up the unused PlayerItemConsumeEvent import since the handler was removed:

Everything is done. Here’s the complete summary:

Changes made to PotionListener.java:

  1. Custom potion color — now uses Color.fromRGB(8439583) (the exact value from the user’s component format)

  2. Jump Boost III embedded directly — addCustomEffect adds Jump Boost (amplifier 2, 3600 ticks = 3 min) to the potion meta, so the effect applies automatically on consumption without needing a PlayerItemConsumeEvent handler

  3. Removed the old onConsume handler — since the effect is now baked into the potion meta via PotionMeta.addCustomEffect(), Bukkit applies it natively when the player drinks it

  4. Cleaned up unused import (PlayerItemConsumeEvent)

Full feature set working:

Feature
How
9 hearts
MagicianManager.applyHealth()
sets
max_health
to 18.0 via XAttribute on join & tag grant
Magician-only crafting
PrepareItemCraftEvent
nulls the result for non-Magicians;
CraftItemEvent
cancels if they try to take it
Froglight Potion recipe
Any froglight (Ochre/Pearlescent/Verdant) + Nether Wart + Water Bottle + Blaze Powder — shapeless, uses
NamespacedKey
so no vanilla conflict
Custom name & lore
Display name “§6Froglight Potion”, lore with “Jump Boost III (3:00)” description
Custom color
Color.fromRGB(8439583)
— matches the exact value from the user’s component format
Jump Boost III on drink
addCustomEffect
in the potion meta, handled natively by Bukkit
Persistent tag
magicians.yml
stores UUIDs, reapplies health on join
E

So what i want to you do so that make the amplifier 3 and rework the tag system to make sure it stays even after server restart

Kodari AI
KodariJul 22 at 9:41 am 1

Two changes needed:

  1. Amplifier → 3 (Jump Boost IV)

  2. Tag system already persists via magicians.yml, but I’ll reinforce it with a proper reload command and ensure onPlayerJoin also resets health for demoted players

All done. Here’s what changed:

1. Amplifier bumped to 3 — Jump Boost IV (3:00) on the Froglight Potion

2. Tag persistence reinforced — It was already saving to magicians.yml, but I added:

  • /magician reload — reloads directly from disk in case of manual edits

  • isMagician(UUID) overload for offline-player lookups

  • Duplicate guards — add on an existing Magician / remove on a non-Magician now return a message instead of silently doing nothing

  • Health reset on join — onPlayerJoin now calls resetHealth() for non-Magicians, so if a player was demoted while offline, their hearts revert to 20 on next login

The tag system writes to magicians.yml on every add/remove, and MagicianPlugin.onDisable() also calls save(). So it persists across restarts, /reload, and server crashes.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
7 407
src/main/java/com/magician/MagicianPlugin.java
package com.magician;

import org.bukkit.plugin.java.JavaPlugin;

public class MagicianPlugin extends JavaPlugin {

    private MagicianManager magicianManager;
    private PotionListener potionListener;

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

        this.magicianManager = new MagicianManager(this);
        this.potionListener = new PotionListener(this, magicianManager);

        getServer().getPluginManager().registerEvents(this.potionListener, this);

        TagCommand tagCommand = new TagCommand(magicianManager);
        getCommand("magician").setExecutor(tagCommand);
        getCommand("magician").setTabCompleter(tagCommand);

        getLogger().info("MagicianPlugin enabled!");
    }

    @Override
    public void onDisable() {
        if (magicianManager != null) {
            magicianManager.save();
        }
        getLogger().info("MagicianPlugin disabled!");
    }

    public MagicianManager getMagicianManager() {
        return magicianManager;
    }

    public PotionListener getPotionListener() {
        return potionListener;
    }
}