Create a Minecraft Paper plugin for version 1.21.11.
Plugin Name: NyanStrike Language: Java API: Paper 1.21.11 Java 21 Maven Project
Features:
- Command: /nyan
- Gives the player a Fishing Rod named "&5Nyan Strike".
- The rod has only 1 durability remaining.
- When used once, it instantly breaks and disappears.
- Nyan Strike
- When the rod is used, detect the hook location.
- Spawn 1000 Wither Skulls 60 blocks above the target location.
- Spawn them randomly within a configurable radius (default 5 blocks).
- The Wither Skulls should fall straight downward like an orbital strike.
- They must NOT disappear while flying.
- They should only disappear after:
- Hitting a block, or - Hitting a player.
- Keep gravity enabled so they naturally fall.
- Impact
When a Wither Skull hits:
- Create a large explosion effect.
- Break surrounding blocks like a normal explosion.
- Remove the Wither Skull after impact.
- Damage
Damage ignores armor, armor toughness, enchantments, shields, and Resistance.
Damage depends on distance from the impact:
- 0–2 blocks = exactly 19 damage
- 2–4 blocks = exactly 15 damage
- 4–6 blocks = exactly 10 damage
- 6–8 blocks = exactly 5 damage
- Beyond 8 blocks = no damage
Apply damage directly through the plugin instead of vanilla explosion damage.
- Command
/nyan set <amount>
Example: /nyan set 1500
Changes how many Wither Skulls are spawned.
Permission: nyanstrike.admin
- Config.yml
skullAmount: 1000 spawnHeight: 60 radius: 5 maxDamage: 19 mediumDamage: 15 lowDamage: 10 minimumDamage: 5
- Effects
- Huge explosion particles.
- Explosion sound.
- Flying smoke particles behind each Wither Skull.
- No lightning.
- No warning sound.
- No countdown.
- Messages
"&dYou received the Nyan Strike Rod!" "&5Nyan Strike Activated!" "&eWither Skull amount set to %amount%."
Requirements
- Paper 1.21.11
- Java 21
- Maven
- plugin.yml
- config.yml
- Clean, optimized code
- No compile errors or warnings
- Compatible with Paper 1.21.115. Knockback
When a Wither Skull impacts:
- Apply powerful knockback to every player within an 8-block radius.
- Knockback ignores armor and shield.
- Knockback strength depends on distance:
• 0–2 blocks: - Deal 19 damage. - Launch player 25 blocks upward. - Throw player 35 blocks away from the explosion.
• 2–4 blocks: - Deal 15 damage. - Launch player 18 blocks upward. - Throw player 25 blocks away.
• 4–6 blocks: - Deal 10 damage. - Launch player 12 blocks upward. - Throw player 15 blocks away.
• 6–8 blocks: - Deal 5 damage. - Launch player 6 blocks upward. - Throw player 8 blocks away.
- Players outside 8 blocks receive no damage or knockback.
- Apply knockback using custom velocity so it is consistent regardless of armor or enchantments.