watkijkjijnaarmij

can you make a protection axe when you do shift right click with it you cant get hit for 8 sec and you make it netherite and a ready when the cooldown it ready and when an entity is atacking you make it the when you hit against a shield

Kodari AI
KodariAug 19 at 12:32 pm 1
GuardianAxe
A Minecraft plugin adding a craftable Netherite Protection Axe. When shift-right-clicked, the player gains 8 seconds of invulnerability to all damage. A cooldown system prevents spam, with a visual ready indicator when the ability is available. While active, attacking an entity with the axe disables their shield, making it an effective offensive and defensive tool. The plugin handles cooldown tracking, particle effects, and configurable messages for seamless integration.

I’ll create a Bukkit/Paper plugin with a custom netherite protection axe, an 8-second shift-right-click invulnerability window, visible READY/cooldown status, incoming-damage protection, shield disabling, and a /protectionaxe command to obtain it.

Created the Protection Axe plugin.

  • Adds a custom Netherite Protection Axe.

  • /protectionaxe gives the axe to authorized players.

  • Shift + right-click activates protection.

  • Prevents all damage for 8 seconds.

  • Displays READY, active status, and remaining seconds in the item name/lore.

  • Axe attacks disable a blocking player’s shield briefly.

  • Includes Paper API, Gradle setup, plugin metadata, and XSeries compatibility.

watkijkjijnaarmij

can you tweak this plugin en make it a neth axe an make it maxed out and i want a configure admin pannel with it and a ready when de cooldoown is over

Kodari AI
KodariAug 19 at 12:33 pm 1
  1. Upgrade the item to a fully enchanted Netherite axe.

  2. Add configurable protection and cooldown settings with persistent config.yml.

  3. Add an admin GUI opened by /protectionaxe admin.

  4. Make the item show READY and notify the player when cooldown expires.

  1. Maxed Netherite axe: added Sharpness V, Efficiency V, Unbreaking III, Mending I, and Fortune III.

  2. Configurable settings: added config.yml with:

    YAML
    protection-duration-seconds: 8
    cooldown-seconds: 30
    
  3. Admin panel: use /protectionaxe admin.

    • Left-click duration/cooldown buttons to decrease by 1 second.

    • Right-click to increase by 1 second.

    • Reload button reloads config.yml.

    • Requires protectionaxe.admin.

  4. Cooldown READY status: the axe changes to (READY) when available and sends: Protection Axe READY!

  5. Command usage: /protectionaxe still gives the axe and requires protectionaxe.give.

watkijkjijnaarmij

and can you make it paper 1.21.11

Kodari AI
KodariAug 19 at 12:34 pm 1
  1. Update the Gradle dependency to Paper API 1.21.11.

  2. Set the Java toolchain to Java 21, required by modern Paper releases.

  3. Update the plugin API version to 1.21 for Paper 1.21.x compatibility.

Updated the plugin for Paper 1.21.11:

  • Paper API: 1.21.11-R0.1-SNAPSHOT

  • Java toolchain: Java 21

  • Plugin API version: 1.21

  • Existing Netherite max-enchant axe, protection ability, cooldown, READY indicator, and admin panel remain unchanged.

watkijkjijnaarmij

mijb hele wereld was gereset door dit kan je dat fixen

Kodari AI
KodariAug 20 at 2:40 pm 1

Ik heb de plugin gecontroleerd: deze code verwijdert of reset geen werelden. Er wordt nergens createWorld, unloadWorld, wereldverwijdering of bestandsverwijdering gebruikt. De plugin werkt alleen met:

  • de Protection Axe;

  • speler-schade;

  • het admin-menu;

  • config.yml.

De wereldreset komt waarschijnlijk door de Paper-update, een andere servermap, een gewijzigde level-name in server.properties, of een beschadigde/ontbrekende wereldmap.

Doe dit eerst:

  1. Zet de server volledig uit.

  2. Hernoem tijdelijk de ProtectionAxe-plugin-JAR of verwijder die uit plugins.

  3. Controleer in server.properties:

    Properties
    level-name=world
    

    Gebruik hier exact de naam van je oorspronkelijke wereldmap.

  4. Controleer of de oude wereldmap nog naast server.jar staat.

  5. Herstel de wereld vanuit een backup voordat je de server opnieuw start.

  6. Start niet opnieuw met een andere lege wereldmap; daardoor kan Paper een nieuwe wereld genereren.

Als de wereldmap echt is overschreven of verwijderd, kan de plugin dat niet terughalen. Gebruik dan een serverbackup of controleer de prullenbak/hosting-backups. Stuur eventueel de eerste 50 regels van de serverconsole en de namen van de mappen naast server.jar; daarmee is te bepalen of Paper de verkeerde wereld heeft geladen.

watkijkjijnaarmij

hij werkt maar als ik dat in mijn playerkits doe en dan claimen werkt hij niet

Kodari AI
KodariAug 23 at 3:43 pm 1
  1. PlayerKits-compatibiliteit: herken de Protection Axe ook wanneer PlayerKits de custom PDC-tag verwijdert.

  2. Bij gebruik wordt de kit-axe opnieuw gemarkeerd en worden naam, READY-status en max-enchants hersteld.

De Protection Axe werkt nu ook wanneer PlayerKits de custom PDC-tag verwijdert bij het opslaan of claimen van de kit.

Aangepast:

  • Herkent Netherite axes met de naam Protection Axe.

  • Herkent ook axes met de maxed enchants:

    • Sharpness V

    • Efficiency V

    • Unbreaking III

    • Mending I

    • Fortune III

  • Zet bij shift-rechtsklik de custom tag opnieuw op de axe.

  • Herstelt automatisch de naam, lore en READY-status.

  • Shield-break functionaliteit werkt hierdoor ook met de PlayerKits-versie.

Herstart de server en claim de kit opnieuw. Gebruik bij voorkeur een nieuwe kit-item nadat de plugin is geüpdatet.

watkijkjijnaarmij

make it so the ready has a glint and its pink but make it if there is another plugin with the ready thing the axe ready goes beside it

1 image attached
Kodari AI
KodariAug 24 at 12:41 pm 1
  1. Make the ready state pink.

  2. Make the axe glint only while ready, while preserving its maxed enchantments.

  3. Keep the axe status attached to the item name/lore so it can coexist with another plugin’s READY display instead of replacing it.

Updated the Protection Axe:

  • READY is now pink/light purple.

  • The axe gets a glint whenever its cooldown is ready.

  • The glint disappears while it is on cooldown.

  • The READY status remains part of the axe’s own name and lore, so another plugin’s READY display can remain beside it instead of being overwritten.

watkijkjijnaarmij

make it just like that and its above the hotbal

Kodari AI
KodariAug 24 at 12:47 pm 1
  1. Add a pink action-bar status above the hotbar while the Protection Axe is held.

  2. Show READY, active protection, or the remaining cooldown without changing the existing glint and item display.

De READY-status staat nu ook boven de hotbar als action bar:

  • READY: roze/lichtpaars

  • ACTIVE: groen

  • Cooldown: rood met resterende seconden

  • Verschijnt wanneer je de Protection Axe in je hoofdhand vasthoudt

  • De bestaande roze glint op de axe blijft behouden zodra hij klaar is

watkijkjijnaarmij

hij moet er meteen staan als je hem in je inventory krijgt

Kodari AI
KodariAug 24 at 12:52 pm 1
  1. Scan the volledige inventory instead of only main/off-hand.

  2. Show the pink READY action bar as soon as the axe enters any inventory slot.

  3. Refresh every tick so kit claims are detected immediately.

De READY-melding verschijnt nu meteen zodra de Protection Axe ergens in je inventory komt, ook via PlayerKits.

Aangepast:

  • Controleert alle inventory-slots, niet alleen je hand.

  • Werkt ook wanneer de axe direct wordt geclaimd.

  • Vernieuwt elke tick voor directe herkenning.

  • De roze Protection Axe: READY action bar blijft behouden.

watkijkjijnaarmij

ik dat die protection axe text weg staat en dan alleen ready in roze kleur and glint

Kodari AI
KodariAug 24 at 12:54 pm 1

Aangepast:

  • De naam Protection Axe is verwijderd.

  • Er staat nu alleen READY in roze op de axe.

  • De axe krijgt alleen een glint wanneer hij klaar is.

  • Boven de hotbar staat ook alleen READY.

  • Tijdens cooldown zie je alleen de resterende seconden.

watkijkjijnaarmij

hij staat niet boven de hotbar

Kodari AI
KodariAug 24 at 2:28 pm 1
  1. Verstuur de status met Paper’s Adventure action-bar API, zodat hij betrouwbaar boven de hotbar verschijnt.

  2. Laat alleen READY in roze zien wanneer de axe ergens in de inventory zit en klaar is.

  3. Houd de glint en cooldown-status intact.

De action bar is aangepast naar Paper’s betrouwbare Adventure API. Daardoor verschijnt alleen READY in roze boven de hotbar zodra de axe in je inventory zit en klaar is. De glint blijft behouden.

watkijkjijnaarmij

can you make it so you detect other plugins that also have the ready thing you need to make it go beside it

1 image attached
Kodari AI
KodariAug 24 at 3:19 pm 1
  1. Inspect the current action-bar implementation and scheduler.

  2. Change the status display so it coexists with other action-bar text instead of replacing it.

  3. Preserve the pink READY text and glint behavior.

Niet automatisch met willekeurige plugins. Minecraft heeft maar één action-bar-regel; de laatste plugin die sendActionBar() gebruikt overschrijft de vorige. De Protection Axe kan de tekst van een andere plugin niet uitlezen.

In de huidige code wordt dit gebruikt:

Java
player.sendActionBar(Component.text("READY", NamedTextColor.LIGHT_PURPLE));

Daarom verdwijnt de tekst van de andere plugin in plaats van ernaast te staan.

Stuur de naam van de andere plugin die zijn eigen READY toont. Dan kan ik:

  1. kijken of die plugin een API heeft om beide teksten te combineren; of

  2. een compatibiliteit toevoegen zodat bijvoorbeeld dit verschijnt:

Plain Text
READY   READY

Zonder plugin-specifieke ondersteuning of ProtocolLib kan dit niet betrouwbaar automatisch worden gedetecteerd.

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

import java.util.Objects;
import org.bukkit.ChatColor;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
import org.bukkit.plugin.java.JavaPlugin;

public final class ProtectionAxePlugin extends JavaPlugin implements CommandExecutor {

    private ProtectionAxeManager manager;

    @Override
    public void onEnable() {
        manager = new ProtectionAxeManager(this);
        getServer().getPluginManager().registerEvents(new ProtectionAxeListener(manager), this);
        Objects.requireNonNull(getCommand("protectionaxe")).setExecutor(this);
        getServer().getScheduler().runTaskTimer(this, manager::tick, 1L, 1L);
    }

    @Override
    public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
        if (!(sender instanceof Player)) {
            sender.sendMessage(ChatColor.RED + "Only players can use this command.");
            return true;
        }

        Player player = (Player) sender;
        if (args.length > 0 && args[0].equalsIgnoreCase("admin")) {
            if (!player.hasPermission("protectionaxe.admin")) {
                player.sendMessage(ChatColor.RED + "You do not have permission to open the admin panel.");
                return true;
            }

            manager.openAdminPanel(player);
            return true;
        }

        if (!player.hasPermission("protectionaxe.give")) {
            player.sendMessage(ChatColor.RED + "You do not have permission to use this command.");
            return true;
        }

        player.getInventory().addItem(manager.createAxe());
        player.sendMessage(ChatColor.GOLD + "You received a Protection Axe.");
        return true;
    }
}