Create a complete, functional Minecraft Java Edition 1.21.11 custom weapons plugin for a Spigot server, inspired by the gameplay concept of Senpai Spider’s Custom Weapon SMP, with original code and mechanics. The plugin must be compatible with Spigot 1.21.11 and use the correct Java version, Bukkit/Spigot API, event handlers, item metadata, persistent data containers, and supported APIs. Do not use outdated APIs, Fabric-only code, Bedrock features, or unsupported methods.
WEAPONS AND ABILITIES
- Crown Hammer
- Create a custom hammer weapon with a unique name, lore, attributes, and custom model data or the appropriate item-model system for Minecraft Java Edition 1.21.11.
- Left-click while airborne to launch the player upward, with a 2-second cooldown.
- Shift + right-click switches between two modes: a max-enchanted Mace with Density V and Wind Burst II, and a max-enchanted Breach V Mace.
- Track kills made with this weapon and Totems of Undying popped by victims hit with it. Unlock the ultimate ability after 3 kills or 5 totems popped.
- Display the progress counter in the weapon's lore or another reliable in-game interface.
- After unlocking, shift + left-click activates an ultimate that sets nearby grass and vegetation within approximately 25 blocks on fire and destroys eligible vegetation. Protect players, protected regions, valuable blocks, and the server from unintended damage.
- Void Reaper
- A dark-themed custom sword dealing 10 base attack damage, with the maximum supported enchantment levels for a Netherite Sword except Knockback.
- Preserve normal Netherite Sword attack speed and cooldown.
- Shift + right-click blinds every other player while excluding the wielder, lasting 10 seconds, with a 10-second cooldown.
- Shift + left-click applies a slow effect and levitates the selected target. When the target reaches approximately 15 blocks above the starting point, trigger a TNT-minecart-style explosion effect. Use safe explosion handling and configurable damage, block destruction, and protection settings. Ability cooldown: 40 seconds.
- Prevent the abilities from triggering repeatedly during a single click or attack.
- Grappling Harpoon
- A custom harpoon with 5 base attack damage and spear-like attack speed.
- Left-click a target to pull the wielder toward that target, even when the target is outside normal melee range or the wielder is airborne.
- Right-click to pull a valid target toward the wielder over approximately 3 seconds.
- Both abilities have independent or shared configurable 15-second cooldowns; make the chosen behavior configurable.
- Implement safe targeting, maximum range settings, velocity limits, fall-damage considerations, and protection against pulling players through protected regions or solid obstacles.
- Kelp Bloom
- A custom kelp-themed sword dealing 7 base attack damage with maximum supported Netherite Sword enchantments and normal Netherite Sword attack speed.
- Shift + right-click creates a large distraction effect after the wielder reaches 3 kills with this weapon. Implement the distraction as configurable particles, sounds, decoys, or another clearly defined server-compatible effect.
- Shift + left-click creates an obsidian prison around a selected target after the required 3 kills. Include a high ceiling and allow the target to escape by mining one layer of the prison.
- Prison ability cooldown: 20 seconds.
- Protect existing builds, prevent permanent trapping, and ensure the prison has a timeout and reliable cleanup system. Never overwrite protected blocks.
- Underwater Weapon 1 — Water
- A custom trident-style weapon with 5 base attack damage, Riptide enchantment, and normal trident attack speed.
- Shift + right-click creates a water-wave or flood effect approximately 25 blocks long and 15 blocks high.
- The weapon cannot be thrown; implement its attack and abilities without allowing the item to be lost.
- Ability cooldown: 60 seconds.
- Prevent uncontrolled liquid spread and unintended flooding. Use a configurable visual or temporary-block effect if actual water placement is unsafe.
- Underwater Weapon 2 — Ice
- A custom trident-style weapon with the same attack damage, attack speed, and enchantment behavior as Underwater Weapon 1.
- Shift + right-click creates an ice-spike formation approximately 10 blocks in diameter and up to 25 blocks long, using packed ice, regular ice, and blue ice for its appearance.
- Ability cooldown: 60 seconds.
- Save every affected block's original state and restore temporary blocks safely. Never permanently replace protected structures or overwrite player builds.
- Underwater Weapon 3 — Water and Ice
- A custom trident-style weapon with the same basic combat properties as the other underwater weapons.
- Shift + right-click activates both the water-wave and ice-spike abilities in a coordinated effect.
- Ability cooldown: 120 seconds.
- Apply the same region protection, temporary-block restoration, and performance safeguards as the other underwater weapons.
- Ultimate God Weapon
- Only one legitimate Ultimate God Weapon should exist on the server by default. Provide configurable administrative controls to create, revoke, transfer, and locate it.
- It is obtained by combining Underwater Weapon 1, Underwater Weapon 2, and Underwater Weapon 3 at a specific custom structure or crafting location. Make the structure's dimensions, blocks, recipe, and activation requirements configurable.
- Its ultimate ability combines water, ice, and kelp-themed effects across an approximately 100 × 100 block area and can affect terrain down to 20 blocks below the surface.
- Implement real block destruction only when explicitly enabled by server configuration and permitted by region-protection rules. Provide a safer default mode using visual effects and temporary terrain changes.
- Use strict limits, asynchronous preparation where appropriate, batched block updates, and configurable cooldowns to prevent server crashes and severe lag. Never perform unsafe Bukkit world modifications asynchronously.
- Include an emergency cancellation mechanism and recovery system for interrupted abilities.
ADMIN COMMANDS Implement permission-protected commands, including:
- "/weapons give <player> all" — gives the player all eight weapons.
- "/weapons give <player> <weapon>" — gives one specific weapon.
- "/weapons list" — lists all available weapons.
- "/weapons reload" — reloads configuration safely.
- "/weapons cooldown reset <player>" — resets weapon cooldowns.
- "/weapons godweapon give <player>" — gives the unique God Weapon, respecting uniqueness rules unless an authorized override is used.
- "/weapons godweapon revoke <player>" — revokes the God Weapon.
- "/weapons help" — displays command usage.
Provide tab completion, clear success and error messages, player-name validation, permission checks, and console support wherever applicable.
ITEM IDENTIFICATION AND SECURITY
- Give each custom weapon a unique persistent identifier using "PersistentDataContainer"; do not identify weapons only by display name or lore.
- Prevent weapon duplication exploits, unauthorized ability activation, cooldown bypasses, and accidental loss during abilities.
- Preserve weapon identity through inventory movement, player death, reconnects, and server restarts wherever applicable.
- Make custom weapon models compatible with a separate resource pack. Document the required model files, model identifiers, and any item-model mappings. Do not assume that a resource pack alone creates functional weapon abilities.
- Store kill counters, totem counters, the unique God Weapon state, and other necessary persistent data safely.
CONFIGURATION Create a complete "config.yml" containing weapon damage, cooldowns, ability ranges, effect durations, kill requirements, particle settings, explosion settings, prison limits, temporary block restoration, region-protection integration, and performance safeguards. Add clear comments and sensible defaults.
PROJECT STRUCTURE AND REQUIRED DELIVERABLES Provide a complete, compilable Java plugin project with:
- All Java source files.
- "plugin.yml" with the correct main class, API version, commands, and permissions.
- "config.yml".
- Any required resource files.
- A Gradle or Maven build configuration with compatible dependencies.
- A README explaining installation, building, commands, permissions, configuration, resource-pack setup, and troubleshooting.
- The compiled plugin JAR, if the environment supports building it.
- A ZIP archive containing the complete source project.
TESTING AND QUALITY REQUIREMENTS
- Verify compilation against the correct Spigot 1.21.11 API.
- Fix compilation errors, missing imports, incorrect event handling, and unsupported APIs.
- Test every weapon's damage, attack speed, abilities, cooldowns, counters, permissions, and item identification.
- Test temporary-block restoration, world protection, reconnects, server restarts, and simultaneous ability activation.
- Handle invalid targets, offline players, unloaded chunks, cancelled events, and missing dependencies safely.
- Use modular, documented, maintainable code rather than one enormous Java class.
- Never claim the plugin is complete or tested unless the corresponding build and tests actually succeeded.
Deliver the actual plugin source code and buildable project, not just an explanation, pseudocode, a design document, or isolated code snippets. If you cannot compile or test the plugin in your environment, state that limitation clearly and provide the exact build and testing steps needed to verify it.