.rykura

make it so whitebeard and black beard both have boss bars and make them wardens and when the anchor is crafted make it have a timer (make it configable) and when the timer is done the anchor drops also give white beard 500 hp and black beard 750 hp and make white beard drop captains cutlass damage of a sword cooldown of a sword ability(shift leftclick) you tp behind your opponent striking them dealing 3.5 hearts and blackbeard drop Hook sword cooldown but axe damage and the ability is when you shift leftclick you pull the nearest player winthin 15 blocks of you towards you also make it so the abilitys are bindind to commands the commands will be /ability1 and /ability2 also make a new command captainsmp:start and make it give 1 random curse or blessing add The anchor Deals 10 attack damage Stuns shields Has a cooldown of around the mace but a bit longer You swirl around throwing your anchor at your enemy dealing 4 hearts of true damage and make it so the menus /blessing /curses /legendaries cant be taken from non opped players make it so you cant pick ur curse / blessing without being opped same thing with the legendaries make the hook a netherite axe and name it pirates hook and make captains cutlass a netherite sword and make pirates hook have the hit cooldown as long as a sword but the damage of an axe same thing with the captains cutlass can you make the anchor a mace and remove its ability and make its ability to dash 5 blocks and rever the attack damage to normal

📎 1 file 5,491 chars
📄
pasted-code-1779691367515.txt
txt 249 lines
▶
Legendary Weapons
The Anchor
Dash Effect
Dark gray smoke bursts from the player’s feet
Water splash particles trail behind while dashing
Small cloud explosion on landing
Looks like:
A pirate slamming forward with force through mist and seawater
Captain’s Cutlass
Teleport Slash
Black smoke appears where you vanished
Thin white slash particles appear behind the enemy
Red critical-hit sparks explode on impact
Small enderman teleport particles swirl briefly
Looks like:
A fast assassin-style blink strike
Pirate’s Hook
Pull Ability
Chains of dark gray particles connect player to target
Fishing-hook style water splash particles travel forward
When target is pulled:
Wind particles spiral around them
Looks like:
A grappling hook violently yanking someone in
Bosses
Whitebeard
Aura
Constant white cloud particles around body
Shockwave rings when attacking
White lightning sparks during enraged phase
Ground crack particles when stomping
Spawn Animation
Massive white explosion cloud
Earthquake effect using falling block dust
Loud lightning flashes

Looks like:

A gigantic earthquake titan
Blackbeard
Aura
Black smoke constantly pours off him
Purple soul particles swirl around body
Darkness pulse every few seconds
Occasional lightning flashes
Spawn Animation
Black fog spreads outward
Purple explosions and soul fire
Warden darkness effect pulse

Looks like:

A shadow emperor consuming the battlefield
CURSES
Curse of the Reaper
Soul Reap
Black and dark red soul particles spiral from target to user
Heart particles rip from enemy chest
Dark mist surrounds stolen victim
Small scythe-shaped slash effect

Looks like:

The target’s life force being ripped away
Fear
Large black smoke burst
Red glowing eye particles around victim
Darkness pulse effect
Chains made of black particles lock target briefly

Looks like:

Pure terror overwhelming the enemy
Reaper’s Resistance
Small wither smoke evaporates harmlessly
Dark aura flickers when wither damage is ignored
Curse of the Thief
Shadow Speed
User dissolves into black smoke
Purple shadow streak trails during teleport
Red slash sparks on hit
Tiny darkness explosion behind target

Looks like:

A rogue assassin emerging from shadows
Thief’s Stealth
Body fades with smoke and shadow particles
Dark swirl remains where player vanished
Weak purple fog around nearby enemies

Looks like:

Becoming one with darkness
Silent Steps
Small black dust instead of footsteps
Nearly invisible movement trail
Curse of Agony
Screech of Agony
Red soundwave ring expands outward
Distorted purple particles shake around victim
Blood-red damage sparks repeatedly hit target

Looks like:

A horrifying scream tearing through minds
Trauma
Charging Phase
Purple-black shield effect around player
Damage absorbed creates glowing red cracks
Release
Giant Warden beam fires outward
Massive soul explosion on impact
Dark shockwave spreads from victim

Looks like:

Stored suffering unleashed all at once
Curse of Crippling
Ground Stomp
Massive dust ring erupts outward
Stone crack particles explode from ground
Shockwave ripples through terrain

Looks like:

A crushing earthquake stomp
Heavy Metal
Iron-colored particles surround body
Slow-moving heavy smoke effect
Metallic sparks flash on damage

Looks like:

Becoming an immovable steel giant
Bone-Locked Curse
White bone fragments appear on hit
Cracks spread visually around target
Root trigger:
Bone cage briefly appears at feet

Looks like:

Bones locking and stiffening
BLESSINGS
Blessing of Hercules
Titan Strike
Golden impact burst
Heavy shockwave ring on hit
Cracked ground particles beneath enemy

Looks like:

A godly punch shattering defenses
Unstoppable Charge
Dust trail behind sprint
Golden wind spirals around player
Explosion burst on collision

Looks like:

A titan charging through enemies
Herculean Strength
Combo streak:
Golden aura intensifies
10-hit combo:
Bright golden flames surround fists

Looks like:

Growing stronger the longer battle continues
Blessing of Zeus
Thunder Judgment
Lightning bolt strikes target
Blue electric sparks spread outward
White thunder ring expands on impact

Looks like:

Divine lightning punishment
Chain Lightning
Electricity jumps between enemies
Blue arcs rapidly chain nearby players
Small lightning explosions on each hit

Looks like:

Battlefield-wide electrical chaos
Divine Charge
Static electricity builds around player
Lightning stacks shown as floating sparks
Fully charged:
Bright glowing electric aura

Looks like:

A storm building inside the player
Blessing of Ares
Blood Fury
Red rage aura surrounds player
Red crit sparks every hit
Smoke pulses intensify while fighting

Looks like:

Entering a berserker war state
War Cry
Giant red shockwave pulse
Soundwave ring bursts outward
Enemies briefly shake visually

Looks like:

A terrifying battlefield roar
Eternal Battle Instinct
Red aura grows stronger over time
Kill effect:
Blood-red burst explosion
Speed wind particles

Looks like:

A warrior feeding off battle momentum
Blessing of Poseidon
Tidal Surge
Massive wave particles crash forward
Water droplets spray outward
Blue foam trails behind wave

Looks like:

An ocean wave smashing enemies away
Abyss Pull
Water vortex forms around target
Blue chains spiral inward
Splash explosion when target gets pulled

Looks like:

The ocean dragging victims into the abyss
Ocean’s Pressure
Calm flowing water aura
Occasional bubble particles
Standing still:
Deep blue protective mist forms

Looks like:

The crushing calm of deep-sea pressure
Kodari AI
KodariMay 25 at 6:50 am 62,204 (v2)
CaptainSMP
A pirate-themed SMP plugin featuring legendary weapons (Anchor/Mace, Captain's Cutlass, Pirate's Hook), powerful boss encounters (Whitebeard & Blackbeard as Wardens with boss bars), and a curse/blessing system. Includes a craftable Anchor with configurable countdown timer, ability commands (/ability1, /ability2), and OP-gated menus for curses, blessings, and legendaries. Features rich particle effects for all abilities and boss auras.

Here’s my plan:

  • Main plugin class + plugin.yml + config.yml

  • Legendary weapons: Anchor (Mace, dash ability), Captain’s Cutlass (Netherite Sword, teleport-slash), Pirate’s Hook (Netherite Axe, pull ability)

  • Boss system: Whitebeard (500hp Warden) + Blackbeard (750hp Warden) with boss bars, auras, spawn animations

  • Curse/Blessing system: 4 curses + 4 blessings with particle effects, OP-gated menus

  • Commands: /ability1, /ability2, captainsmp:start, /blessing, /curses, /legendaries

Now I need to fix the BlessingManager.setPlayerBlessing to accept null, and fix the BossListener which calls getBossType after removeBoss (which removes the entry). Let me also fix the MenuListener null-setting issue.

I can see the BossListener has a bug — it calls getBossType after removeBoss. Let me read all the remaining files to get a full picture before writing everything properly.

Good — I have a full picture. I can see several issues to fix:

  1. BossListener: calls getBossType after removeBoss (entry already removed) — need to get type first

  2. MenuListener: calls setPlayerBlessing(uuid, null) but HashMap.put(key, null) works fine, however setPlayerCurse(uuid, null) also needs to work — these are fine actually since HashMap allows null values

  3. BossManager: uses Attribute.GENERIC_MAX_HEALTH without import, and Sound/Particle directly (not XSeries-wrapped) — these are Bukkit enums used directly which is fine for internal Bukkit API (Sound/Particle are not cross-version breaking in the same way for 1.20+)

  4. plugin.yml: missing captainsmp:start namespace alias — the command is captainsmp with subcommand start, that’s fine

  5. BossListener: the critical bug — getBossType called after removeBoss

Let me fix the BossListener bug and also add the missing Attribute import to BossManager:

Now let me also add the missing Attribute import to BossManager and fix the Sound/Particle direct enum usage (these need to be valid for the target version):

Now let me create the build.gradle:

CaptainSMP
A pirate-themed SMP plugin featuring legendary weapons (Anchor/Mace with dash, Captain's Cutlass with teleport-slash, Pirate's Hook with pull), Warden boss encounters (Whitebeard 500HP & Blackbeard 750HP) with boss bars and particle auras, and a curse/blessing system (4 curses, 4 blessings). Includes craftable Anchor with configurable countdown timer, /ability1 & /ability2 commands, OP-gated menus for curses/blessings/legendaries, and captainsmp:start to assign random curses or blessings.

Here’s a summary of everything built:

Legendary Weapons

  • The Anchor — Mace, dash 5 blocks forward (shift+LClick or /ability1), smoke/water particles on dash and landing

  • Captain’s Cutlass — Netherite Sword, teleport behind nearest enemy dealing 3.5 hearts (7 damage), black smoke + crit sparks

  • Pirate’s Hook — Netherite Axe, pull nearest player within 15 blocks, chain particles connecting attacker to target

Bosses

  • Whitebeard — Warden, 500HP, white boss bar, white cloud/ash aura, lightning spawn animation, enraged phase (white sparks below 50% HP)

  • Blackbeard — Warden, 750HP, purple boss bar, squid ink/soul smoke aura, black fog spawn animation, soul fire enraged phase

  • Both drop their respective legendary on death; boss bars auto-add to joining players

Crafting System

  • Anchor recipe: ICI / IAI / ICI (Iron, Chain, Anvil) — cancels the craft, starts a configurable countdown (default 60s), then drops the item at the craft location with a broadcast

Curse/Blessing System (4 each, OP-gated menus)

  • Curses: Reaper (soul reap + fear), Thief (shadow speed + stealth), Agony (screech + trauma), Crippling (ground stomp + heavy metal)

  • Blessings: Hercules (titan strike + charge), Zeus (thunder judgment + chain lightning), Ares (blood fury + war cry), Poseidon (tidal surge + abyss pull)

Commands: /ability1, /ability2, /blessing, /curses, /legendaries, /captainsmp start

Bug fixed: BossListener now captures boss type before calling removeBoss to avoid a null lookup on the already-removed entry.

.rykura

The compilation failed with this error:

code
Compilation failed with 43 error(s):

ERROR in src/main/java/com/captainsmp/listeners/CraftingListener.java at line 33: cannot find symbol
        recipe.setIngredient('C', Material.CHAIN);
                                          ^
  symbol: variable CHAIN
  location: class Material

ERROR in src/main/java/com/captainsmp/listeners/CraftingListener.java at line 66: cannot find symbol
            dropLoc.getWorld().spawnParticle(Particle.EXPLOSION_HUGE, dropLoc, 2, 0, 0, 0, 0);
                                                     ^
  symbol: variable EXPLOSION_HUGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 39: cannot find symbol
        warden.getAttribute(Attribute.GENERIC_MAX_HEALTH).setBaseValue(health);
                                     ^
  symbol: variable GENERIC_MAX_HEALTH
  location: interface Attribute

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 64: cannot find symbol
        warden.getAttribute(Attribute.GENERIC_MAX_HEALTH).setBaseValue(health);
                                     ^
  symbol: variable GENERIC_MAX_HEALTH
  location: interface Attribute

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 89: cannot find symbol
                world.spawnParticle(Particle.EXPLOSION_LARGE, loc, 3, 1, 0.5, 1, 0);
                                            ^
  symbol: variable EXPLOSION_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 96: cannot find symbol
            world.spawnParticle(Particle.EXPLOSION_HUGE, loc, 1, 0, 0, 0, 0);
                                        ^
  symbol: variable EXPLOSION_HUGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 113: cannot find symbol
                world.spawnParticle(Particle.SMOKE_LARGE, loc, 40, 2, 1, 2, 0.1);
                                            ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 118: cannot find symbol
            world.spawnParticle(Particle.EXPLOSION_HUGE, loc, 2, 1, 0, 1, 0);
                                        ^
  symbol: variable EXPLOSION_HUGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 135: cannot find symbol
            double maxHealth = warden.getAttribute(Attribute.GENERIC_MAX_HEALTH).getValue();
                                                            ^
  symbol: variable GENERIC_MAX_HEALTH
  location: interface Attribute

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 157: cannot find symbol
            double maxHealth = warden.getAttribute(Attribute.GENERIC_MAX_HEALTH).getValue();
                                                            ^
  symbol: variable GENERIC_MAX_HEALTH
  location: interface Attribute

ERROR in src/main/java/com/captainsmp/bosses/BossManager.java at line 170: cannot find symbol
        double maxHealth = entity.getAttribute(Attribute.GENERIC_MAX_HEALTH).getValue();
                                                        ^
  symbol: variable GENERIC_MAX_HEALTH
  location: interface Attribute

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 78: cannot find symbol
        from.getWorld().spawnParticle(Particle.SMOKE_LARGE, from, 20, 0.3, 0.5, 0.3, 0.05);
                                              ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 120: cannot find symbol
        targetLoc.getWorld().spawnParticle(Particle.WATER_SPLASH, targetLoc, 20, 0.5, 0.5, 0.5, 0.1);
                                                   ^
  symbol: variable WATER_SPLASH
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 140: cannot find symbol
        from.getWorld().spawnParticle(Particle.SMOKE_LARGE, from, 15, 0.3, 0.3, 0.3, 0.05);
                                              ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 141: cannot find symbol
        from.getWorld().spawnParticle(Particle.WATER_SPLASH, from, 10, 0.3, 0.3, 0.3, 0.05);
                                              ^
  symbol: variable WATER_SPLASH
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 147: cannot find symbol
            land.getWorld().spawnParticle(Particle.EXPLOSION_NORMAL, land, 10, 0.5, 0.2, 0.5, 0.05);
                                                  ^
  symbol: variable EXPLOSION_NORMAL
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 209: cannot find symbol
        tLoc.getWorld().spawnParticle(Particle.SMOKE_LARGE, tLoc, 15, 0.5, 0.5, 0.5, 0.05);
                                              ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 230: cannot find symbol
            tLoc.getWorld().spawnParticle(Particle.SMOKE_LARGE, tLoc, 20, 0.5, 1, 0.5, 0.1);
                                                  ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 235: cannot find symbol
                    org.bukkit.potion.PotionEffectType.SLOW, 60, 2));
                                                      ^
  symbol: variable SLOW
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 259: cannot find symbol
        tLoc.getWorld().spawnParticle(Particle.SMOKE_NORMAL, tLoc, 10, 0.3, 0.3, 0.3, 0.05);
                                              ^
  symbol: variable SMOKE_NORMAL
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 272: cannot find symbol
        loc.getWorld().spawnParticle(Particle.SMOKE_LARGE, loc, 20, 0.5, 1, 0.5, 0.05);
                                             ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 295: cannot find symbol
                spawnRingParticles(loc, Particle.CRIT_MAGIC, radius, 20);
                                                ^
  symbol: variable CRIT_MAGIC
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 296: cannot find symbol
                spawnRingParticles(loc, Particle.SMOKE_NORMAL, radius, 10);
                                                ^
  symbol: variable SMOKE_NORMAL
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 305: cannot find symbol
                    org.bukkit.potion.PotionEffectType.CONFUSION, 80, 0));
                                                      ^
  symbol: variable CONFUSION
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 322: cannot find symbol
                org.bukkit.potion.PotionEffectType.DAMAGE_RESISTANCE, 60, 2));
                                                  ^
  symbol: variable DAMAGE_RESISTANCE
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 326: cannot find symbol
            releaseLoc.getWorld().spawnParticle(Particle.EXPLOSION_HUGE, releaseLoc, 3, 1, 0, 1, 0);
                                                        ^
  symbol: variable EXPLOSION_HUGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 351: cannot find symbol
                spawnRingParticles(loc, Particle.BLOCK_CRACK, radius, 30,
                                                ^
  symbol: variable BLOCK_CRACK
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 353: cannot find symbol
                spawnRingParticles(loc, Particle.SMOKE_LARGE, radius, 10);
                                                ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 362: cannot find symbol
                    org.bukkit.potion.PotionEffectType.SLOW, 60, 2));
                                                      ^
  symbol: variable SLOW
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 378: cannot find symbol
                org.bukkit.potion.PotionEffectType.DAMAGE_RESISTANCE, 100, 2));
                                                  ^
  symbol: variable DAMAGE_RESISTANCE
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 380: cannot find symbol
                org.bukkit.potion.PotionEffectType.SLOW, 100, 1));
                                                  ^
  symbol: variable SLOW
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 382: cannot find symbol
                org.bukkit.potion.PotionEffectType.INCREASE_DAMAGE, 100, 1));
                                                  ^
  symbol: variable INCREASE_DAMAGE
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 400: cannot find symbol
        tLoc.getWorld().spawnParticle(Particle.EXPLOSION_NORMAL, tLoc, 10, 0.5, 0.3, 0.5, 0.05);
                                              ^
  symbol: variable EXPLOSION_NORMAL
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 430: cannot find symbol
                eLoc.getWorld().spawnParticle(Particle.EXPLOSION_NORMAL, eLoc, 5, 0.3, 0.3, 0.3, 0.05);
                                                      ^
  symbol: variable EXPLOSION_NORMAL
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 482: cannot find symbol
        loc.getWorld().spawnParticle(Particle.SMOKE_LARGE, loc, 10, 0.5, 1, 0.5, 0.05);
                                             ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 485: cannot find symbol
                org.bukkit.potion.PotionEffectType.INCREASE_DAMAGE, 100, 1));
                                                  ^
  symbol: variable INCREASE_DAMAGE
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 501: cannot find symbol
        spawnRingParticles(loc, Particle.SMOKE_LARGE, 5, 20);
                                        ^
  symbol: variable SMOKE_LARGE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 507: cannot find symbol
                    org.bukkit.potion.PotionEffectType.SLOW, 60, 1));
                                                      ^
  symbol: variable SLOW
  location: class PotionEffectType

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 528: cannot find symbol
                waveLoc.getWorld().spawnParticle(Particle.WATER_SPLASH, waveLoc, 20, 1, 0.5, 1, 0.1);
                                                         ^
  symbol: variable WATER_SPLASH
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 529: cannot find symbol
                waveLoc.getWorld().spawnParticle(Particle.WATER_BUBBLE, waveLoc, 10, 0.5, 0.5, 0.5, 0.05);
                                                         ^
  symbol: variable WATER_BUBBLE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 559: cannot find symbol
            spawnSpiralParticles(tLoc, Particle.WATER_BUBBLE, 15, 1.5);
                                               ^
  symbol: variable WATER_BUBBLE
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 560: cannot find symbol
            tLoc.getWorld().spawnParticle(Particle.WATER_SPLASH, tLoc, 15, 0.5, 0.5, 0.5, 0.1);
                                                  ^
  symbol: variable WATER_SPLASH
  location: class Particle

ERROR in src/main/java/com/captainsmp/abilities/AbilityManager.java at line 604: cannot find symbol
        world.spawnParticle(Particle.WATER_SPLASH, from, 10, 0.3, 0.3, 0.3, 0.05);
                                    ^
  symbol: variable WATER_SPLASH
  location: class Particle


=== COMPILATION ERROR ANALYSIS ===

FILES TO INVESTIGATE:
  - src/main/java/com/captainsmp/listeners/CraftingListener.java
  - src/main/java/com/captainsmp/bosses/BossManager.java
  - src/main/java/com/captainsmp/abilities/AbilityManager.java

Please fix this error by creating a new artifact with the corrected code.

Kodari AI
KodariMay 25 at 6:54 am 30,622 (v2)

All errors are renamed Bukkit enum values in 1.21+. Here’s the mapping:

  • Particle.SMOKE_LARGE → LARGE_SMOKE

  • Particle.SMOKE_NORMAL → SMOKE

  • Particle.EXPLOSION_HUGE → EXPLOSION_EMITTER

  • Particle.EXPLOSION_LARGE → EXPLOSION

  • Particle.EXPLOSION_NORMAL → POOF

  • Particle.WATER_SPLASH → SPLASH

  • Particle.WATER_BUBBLE → BUBBLE

  • Particle.BLOCK_CRACK → BLOCK

  • Particle.CRIT_MAGIC → ENCHANTED_HIT

  • Attribute.GENERIC_MAX_HEALTH → XAttribute via XAttribute.of("generic.max_health")

  • Material.CHAIN → valid in 1.16+, use XMaterial

  • PotionEffectType.SLOW → SLOWNESS

  • PotionEffectType.CONFUSION → NAUSEA

  • PotionEffectType.DAMAGE_RESISTANCE → RESISTANCE

  • PotionEffectType.INCREASE_DAMAGE → STRENGTHGiven the large number of replacements across three files, I’ll do full rewrites for clarity and correctness.

All 43 errors fixed across the three files:

  • Particles: Renamed to 1.21+ names — SMOKE_LARGE→LARGE_SMOKE, SMOKE_NORMAL→SMOKE, EXPLOSION_HUGE→EXPLOSION_EMITTER, EXPLOSION_LARGE→EXPLOSION, EXPLOSION_NORMAL→POOF, WATER_SPLASH→SPLASH, WATER_BUBBLE→BUBBLE, BLOCK_CRACK→BLOCK, CRIT_MAGIC→ENCHANTED_HIT

  • PotionEffectType: SLOW→SLOWNESS, CONFUSION→NAUSEA, DAMAGE_RESISTANCE→RESISTANCE, INCREASE_DAMAGE→STRENGTH

  • Attribute: Replaced Attribute.GENERIC_MAX_HEALTH with XAttribute.of("generic.max_health") for cross-version safety

  • Material.CHAIN: Replaced with XMaterial.matchXMaterial("CHAIN") lookup in CraftingListener

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
21 1,790
src/main/java/com/captainsmp/CaptainSMP.java
package com.captainsmp;

import com.captainsmp.abilities.AbilityManager;
import com.captainsmp.bosses.BossManager;
import com.captainsmp.commands.*;
import com.captainsmp.curses.CurseManager;
import com.captainsmp.blessings.BlessingManager;
import com.captainsmp.items.LegendaryItemManager;
import com.captainsmp.listeners.*;
import org.bukkit.plugin.java.JavaPlugin;

public class CaptainSMP extends JavaPlugin {

    private static CaptainSMP instance;
    private BossManager bossManager;
    private AbilityManager abilityManager;
    private CurseManager curseManager;
    private BlessingManager blessingManager;
    private LegendaryItemManager legendaryItemManager;

    @Override
    public void onEnable() {
        instance = this;
        saveDefaultConfig();

        legendaryItemManager = new LegendaryItemManager(this);
        curseManager = new CurseManager(this);
        blessingManager = new BlessingManager(this);
        abilityManager = new AbilityManager(this);
        bossManager = new BossManager(this);

        getServer().getPluginManager().registerEvents(new CraftingListener(this), this);
        getServer().getPluginManager().registerEvents(new AbilityListener(this), this);
        getServer().getPluginManager().registerEvents(new BossListener(this), this);
        getServer().getPluginManager().registerEvents(new MenuListener(this), this);
        getServer().getPluginManager().registerEvents(new WeaponListener(this), this);

        getCommand("ability1").setExecutor(new AbilityCommand(this, 1));
        getCommand("ability2").setExecutor(new AbilityCommand(this, 2));
        getCommand("blessing").setExecutor(new BlessingCommand(this));
        getCommand("curses").setExecutor(new CursesCommand(this));
        getCommand("legendaries").setExecutor(new LegendariesCommand(this));
        getCommand("captainsmp").setExecutor(new CaptainSMPCommand(this));

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

    @Override
    public void onDisable() {
        if (bossManager != null) bossManager.cleanup();
        getLogger().info("CaptainSMP disabled!");
    }

    public static CaptainSMP getInstance() { return instance; }
    public BossManager getBossManager() { return bossManager; }
    public AbilityManager getAbilityManager() { return abilityManager; }
    public CurseManager getCurseManager() { return curseManager; }
    public BlessingManager getBlessingManager() { return blessingManager; }
    public LegendaryItemManager getLegendaryItemManager() { return legendaryItemManager; }
}