voidplyz.
๐Ÿ“Ž 1 file 18,865 chars
๐Ÿ“„
pasted-code-1788013258123.txt
txt 943 lines
โ–ถ
Yes. Since you want to **build the plugin first and make the resource pack afterward**, use this prompt in your coding AI.

I would use this as the **master plugin prompt**:

```text
You are an expert Java developer and Minecraft Paper plugin developer.

Create a COMPLETE, production-ready Minecraft custom weapons plugin called:

LagBrosWeapons

Do NOT create the resource pack yet.

The plugin must be designed so that I can create a matching resource pack later. Therefore, establish a clean and documented custom item-model ID system that the future resource pack can use.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
TARGET
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Minecraft Java Edition: 1.21.11
Server: Paper 1.21.11
Java: 21

The plugin must be server-side only.

Compatibility goals:
- Paper 1.21.11
- ViaVersion
- ViaBackwards
- GeyserMC
- Floodgate
- Grim Anticheat
- WorldGuard

ViaVersion, ViaBackwards, Geyser, Floodgate, Grim, and WorldGuard must be OPTIONAL integrations.

The plugin must still start and work if none of those plugins are installed.

Do not use exploit techniques or anti-cheat bypasses.

Prefer Paper/Bukkit API and Adventure API.

Avoid NMS unless absolutely necessary.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
IMPORTANT ARCHITECTURE
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Create a clean modular plugin.

Do NOT put everything inside one Java class.

Use a structure similar to:

com.lagbros.weapons

โ”œโ”€โ”€ LagBrosWeapons.java
โ”‚
โ”œโ”€โ”€ weapon/
โ”‚   โ”œโ”€โ”€ Weapon.java
โ”‚   โ”œโ”€โ”€ WeaponManager.java
โ”‚   โ”œโ”€โ”€ WeaponType.java
โ”‚   โ””โ”€โ”€ WeaponRegistry.java
โ”‚
โ”œโ”€โ”€ item/
โ”‚   โ”œโ”€โ”€ WeaponItem.java
โ”‚   โ”œโ”€โ”€ WeaponItemBuilder.java
โ”‚   โ”œโ”€โ”€ WeaponIdentifier.java
โ”‚   โ””โ”€โ”€ WeaponDurability.java
โ”‚
โ”œโ”€โ”€ ability/
โ”‚   โ”œโ”€โ”€ WeaponAbility.java
โ”‚   โ”œโ”€โ”€ TempestBlitzAbility.java
โ”‚   โ”œโ”€โ”€ VolcanicFractureAbility.java
โ”‚   โ”œโ”€โ”€ OceanicVortexAbility.java
โ”‚   โ”œโ”€โ”€ LeviathanWrathAbility.java
โ”‚   โ””โ”€โ”€ SingularityShotAbility.java
โ”‚
โ”œโ”€โ”€ combat/
โ”‚   โ”œโ”€โ”€ DamageManager.java
โ”‚   โ”œโ”€โ”€ CooldownManager.java
โ”‚   โ””โ”€โ”€ ReachManager.java
โ”‚
โ”œโ”€โ”€ recipe/
โ”‚   โ”œโ”€โ”€ RecipeManager.java
โ”‚   โ”œโ”€โ”€ RecipeEditor.java
โ”‚   โ””โ”€โ”€ RecipeData.java
โ”‚
โ”œโ”€โ”€ command/
โ”‚   โ”œโ”€โ”€ WeaponsCommand.java
โ”‚   โ””โ”€โ”€ WeaponsTabCompleter.java
โ”‚
โ”œโ”€โ”€ listener/
โ”‚   โ”œโ”€โ”€ WeaponDamageListener.java
โ”‚   โ”œโ”€โ”€ WeaponInteractListener.java
โ”‚   โ”œโ”€โ”€ ProjectileListener.java
โ”‚   โ”œโ”€โ”€ InventoryListener.java
โ”‚   โ””โ”€โ”€ PlayerJoinListener.java
โ”‚
โ”œโ”€โ”€ compatibility/
โ”‚   โ”œโ”€โ”€ ViaVersionHook.java
โ”‚   โ”œโ”€โ”€ GeyserHook.java
โ”‚   โ”œโ”€โ”€ FloodgateHook.java
โ”‚   โ””โ”€โ”€ WorldGuardHook.java
โ”‚
โ””โ”€โ”€ util/
    โ”œโ”€โ”€ LocationUtil.java
    โ”œโ”€โ”€ ParticleUtil.java
    โ””โ”€โ”€ SoundUtil.java

You may improve this architecture if necessary, but keep the code modular and maintainable.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
5 CUSTOM WEAPONS
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Create EXACTLY these five weapons.

โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
1. ZEPHYR'S EDGE
โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€

Weapon ID:

zephyrs_edge

Display name:

Zephyr's Edge

Attack Damage:
24

Normal attack cooldown:
2.0 seconds

Reach bonus:
1.5 blocks

Durability:
6000

Future resource-pack model ID:

zephyrs_edge

Also create a clearly documented internal model identifier:

lagbrosweapons:zephyrs_edge

ABILITY:

TEMPEST BLITZ

Activation:
Right-click

Behavior:
- Dash forward up to 10 blocks.
- Damage enemies encountered along the path.
- Deal 20 true damage.
- Grant Speed IV for 5 seconds.
- Ability cooldown: 4 seconds.
- Add wind particles.
- Add appropriate sound effects.

Safety:
- Never teleport into solid blocks.
- Never teleport into the void.
- Never teleport outside world border.
- Find a safe destination.
- Respect WorldGuard protection if installed.
- Do not allow the ability to bypass protected regions.
- Prevent spam.
- Prevent repeated teleport abuse.

โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
2. CINDERSTRIKE
โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€

Weapon ID:

cinderstrike

Display name:

Cinderstrike

Attack Damage:
34

Normal attack cooldown:
1.1 seconds

Reach bonus:
1.0 block

Durability:
7500

Future resource-pack model ID:

cinderstrike

Internal model identifier:

lagbrosweapons:cinderstrike

ABILITY:

VOLCANIC FRACTURE

Critical hit:
- Disable enemy shields for 10 seconds.

Special activation:
- Sneak + left-click.

Behavior:
- Create a 7x7 zone.
- Launch magma spikes from the ground.
- Each successful hit deals 18 blast damage.
- Apply burning/fire effect.
- Ability cooldown: 5 seconds.
- Create volcanic particles and sounds.

IMPORTANT:
- Do NOT permanently destroy blocks.
- Do NOT grief terrain.
- Respect WorldGuard.
- Limit entities and particles for performance.

โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
3. TIDECALLER'S HARPOON
โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€

Weapon ID:

tidecallers_harpoon

Display name:

Tidecaller's Harpoon

Melee Damage:
26

Ranged Damage:
32

Normal attack cooldown:
1.4 seconds

Reach bonus:
3.0 blocks

Durability:
6500

Future resource-pack model ID:

tidecallers_harpoon

Internal model identifier:

lagbrosweapons:tidecallers_harpoon

ABILITY:

OCEANIC VORTEX

Behavior:
- Throw a harpoon projectile.
- Projectile travels forward.
- It can hit multiple entities in a line.
- Pull affected entities toward the player.
- Apply Slowness VI for 4 seconds.
- Successful activation resets the normal attack cooldown.
- Ability cooldown: 3 seconds.

Safety:
- Prevent projectile abuse.
- Prevent hitting through protected regions.
- Limit maximum affected entities.
- Clean up projectile data.
- Do not create excessive entities.

โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
4. ABYSSAL IMPALER
โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€

Weapon ID:

abyssal_impaler

Display name:

Abyssal Impaler

Melee Damage:
28

Ranged Damage:
36

Normal attack cooldown:
1.2 seconds

Reach bonus:
3.5 blocks

Durability:
8000

Future resource-pack model ID:

abyssal_impaler

Internal model identifier:

lagbrosweapons:abyssal_impaler

ABILITY:

LEVIATHAN WRATH

Behavior:
- Create a geyser at impact.
- Knock affected enemies up to 12 blocks into the air.
- Remove active positive potion effects.
- Deal 15 magic damage.
- Ability cooldown: 4 seconds.

Safety:
- Safe knockback.
- Respect world border.
- Do not launch players into invalid locations.
- Respect WorldGuard.
- Limit affected entities.

โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
5. ECLIPSE LONGBOW
โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€

Weapon ID:

eclipse_longbow

Display name:

Eclipse Longbow

Full-draw damage:
40

Charge time:
0.5 seconds

Reach:
Infinite

Durability:
5000

Future resource-pack model ID:

eclipse_longbow

Internal model identifier:

lagbrosweapons:eclipse_longbow

ABILITY:

SINGULARITY SHOT

Behavior:
- Fire a special arrow.
- The arrow can penetrate up to 5 blocks of solid terrain.
- Detonate at impact.
- Create a black-hole/singularity visual effect.
- Pull nearby targets toward the impact.
- Apply Wither III for 6 seconds.
- Ability cooldown must be configurable.

Safety:
- Do not permanently destroy terrain.
- Respect WorldGuard.
- Respect world border.
- Limit affected entities.
- Limit particles.
- Prevent lag.
- Prevent projectile duplication.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
CUSTOM ITEM IDENTIFICATION
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

This is extremely important.

Do NOT identify weapons using:
- display name
- lore
- vanilla material
- CustomModelData alone

Use PersistentDataContainer.

Every weapon must contain:

lagbrosweapons:weapon_id

Example:

lagbrosweapons:weapon_id = zephyrs_edge

Also store:

lagbrosweapons:weapon_version

and:

lagbrosweapons:durability

The weapon must remain identifiable after:
- renaming
- moving inventory
- dropping
- picking up
- putting into chests
- restarting the server

Do not break normal Minecraft items.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
FUTURE RESOURCE PACK COMPATIBILITY
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Do NOT generate a resource pack now.

However, prepare the plugin so I can create one later.

Every weapon must have a configurable model identifier:

weapon-model: "lagbrosweapons:zephyrs_edge"

etc.

The plugin should use the correct modern Minecraft 1.21.11 item-model API/data where appropriate.

Keep model assignment separate from gameplay identification.

Gameplay identity:
PDC weapon_id

Visual identity:
item model identifier

This separation is REQUIRED.

Create documentation explaining exactly how the future resource pack should map:

lagbrosweapons:zephyrs_edge
lagbrosweapons:cinderstrike
lagbrosweapons:tidecallers_harpoon
lagbrosweapons:abyssal_impaler
lagbrosweapons:eclipse_longbow

to their respective models.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
CUSTOM DURABILITY
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Do NOT rely only on vanilla durability.

Track custom durability using PDC.

Values:

Zephyr's Edge = 6000
Cinderstrike = 7500
Tidecaller's Harpoon = 6500
Abyssal Impaler = 8000
Eclipse Longbow = 5000

Display durability in lore:

Durability: 6000/6000

Update the lore when durability changes.

Prevent:
- negative durability
- durability overflow
- ability usage at zero durability

Make durability loss configurable.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
COMBAT
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Implement custom attack damage carefully.

Prevent:
- double damage
- duplicate projectile damage
- event recursion
- ability damage being triggered twice

Support:
- melee
- ranged
- true damage
- magic damage
- knockback
- potion effects

Make damage values configurable.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
ATTACK SPEED / COOLDOWNS
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Do NOT confuse attack speed with ability cooldown.

Keep these separate.

Example:

attack-cooldown: 2.0
ability-cooldown: 4.0

Use a proper timestamp-based cooldown manager.

Do NOT use Thread.sleep().

Do NOT block the server thread.

Optional cooldown display:
- Action bar
- Boss bar

Make configurable.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
REACH
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Implement configurable reach bonuses.

Values:

Zephyr's Edge = +1.5
Cinderstrike = +1.0
Tidecaller's Harpoon = +3.0
Abyssal Impaler = +3.5
Eclipse Longbow = infinite ranged reach

Do NOT create anti-cheat bypasses.

Do not use impossible client-side behavior.

Validate line of sight and target distance.

If a reach mechanic cannot be implemented safely using Paper API, explain the limitation and implement the safest server-side alternative.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
RECIPES
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Every weapon must have a crafting recipe.

Recipes must be stored separately:

plugins/LagBrosWeapons/recipes.yml

Create an OP-only recipe editor.

Command:

/weapons recipe set 

Opening the command should open a 3x3 recipe editor GUI.

GUI:

3x3 crafting grid

Buttons:
SAVE
CANCEL
RESET
CLEAR

Admin places ingredients into the grid and clicks SAVE.

Save the recipe to recipes.yml.

Recipe changes must survive restart.

Commands:

/weapons recipe set 
/weapons recipe view 
/weapons recipe reset 
/weapons recipe reload

Only OP or:

lagbrosweapons.recipe

can modify recipes.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
COMMANDS
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Main command:

/weapons

Implement:

/weapons give   [amount]
/weapons list
/weapons info 
/weapons reload
/weapons recipe set 
/weapons recipe view 
/weapons recipe reset 
/weapons recipe reload
/weapons durability   
/weapons debug 

Permissions:

lagbrosweapons.admin
lagbrosweapons.give
lagbrosweapons.recipe
lagbrosweapons.reload

OP automatically has administrator access.

Implement tab completion.

Use Adventure API for messages.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
CONFIGURATION
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Create:

config.yml
weapons.yml
recipes.yml
messages.yml

Do not hard-code important values.

Example weapons.yml:

weapons:

  zephyrs_edge:
    display-name: "Zephyr's Edge"
    material: DIAMOND_SWORD
    attack-damage: 24.0
    attack-cooldown: 2.0
    reach: 1.5
    durability: 6000
    model: "lagbrosweapons:zephyrs_edge"
    ability: "tempest_blitz"

etc.

Use appropriate Paper 1.21.11 material/API names.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
GEYSER / FLOODGATE
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Geyser and Floodgate are optional.

The plugin must still work without them.

Bedrock players must be able to use the weapons.

If Bedrock cannot display the future custom model:
- use a safe fallback appearance
- keep the weapon's name
- keep gameplay
- keep abilities

Do not require a Bedrock resource pack.

Do not use Java-client-only behavior for core gameplay.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
VIAVERSION / VIABACKWARDS
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

ViaVersion and ViaBackwards are optional.

Do not send unsupported packets.

Do not assume every player is on 1.21.11.

Gameplay should continue working on supported older clients where possible.

If a client cannot display the future custom model:
- fallback appearance
- preserve name/lore
- preserve gameplay

Do not kick players because of resource-pack/model incompatibility.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
GRIM ANTICHEAT
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

The plugin must be compatible with Grim Anticheat.

DO NOT attempt to bypass Grim.

Do NOT use:
- packet spoofing
- fake movement
- impossible velocity
- rotation exploits
- anti-cheat bypasses

All abilities must be legitimate server-side mechanics.

For movement abilities:
- validate destinations
- avoid repeated teleports
- check collision
- respect world border

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
WORLDGUARD
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

WorldGuard must be optional.

If installed:
- respect protected regions
- do not damage protected entities where prohibited
- do not modify protected blocks
- do not bypass region restrictions

If WorldGuard isn't installed, the plugin must still work.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
PERFORMANCE
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

The plugin must be suitable for multiplayer servers.

Avoid:
- huge area scans
- unnecessary repeating tasks
- thousands of particles
- thousands of entities
- memory leaks
- permanent Player object references

Limit:
- targets
- particles
- projectile lifetime
- ability area

Use efficient collections.

Clean cooldowns when players leave.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
FILES
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Create the complete project.

Expected:

LagBrosWeapons/
โ”œโ”€โ”€ pom.xml
โ”œโ”€โ”€ README.md
โ””โ”€โ”€ src/
    โ””โ”€โ”€ main/
        โ”œโ”€โ”€ java/
        โ”‚   โ””โ”€โ”€ com/lagbros/weapons/
        โ””โ”€โ”€ resources/
            โ”œโ”€โ”€ plugin.yml
            โ”œโ”€โ”€ config.yml
            โ”œโ”€โ”€ weapons.yml
            โ”œโ”€โ”€ recipes.yml
            โ””โ”€โ”€ messages.yml

Do NOT create resource-pack files yet.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
PLUGIN.YML
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Create a correct Paper plugin.yml for Minecraft 1.21.11.

Use the correct main class.

Define:

/weapons

permissions.

Use soft-depend/optional dependency handling for integrations where appropriate.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
README
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Create a detailed README explaining:

1. Requirements
2. Java version
3. Paper version
4. Installation
5. Commands
6. Permissions
7. Configuration
8. Weapon statistics
9. Ability mechanics
10. Recipe editor
11. PDC weapon identification
12. Future resource-pack integration
13. Model identifier system
14. ViaVersion compatibility
15. ViaBackwards compatibility
16. Geyser compatibility
17. Floodgate compatibility
18. Grim compatibility
19. WorldGuard compatibility
20. Troubleshooting
21. Testing

IMPORTANT:
Include a dedicated section:

"HOW TO CREATE THE RESOURCE PACK LATER"

Explain exactly which identifiers the resource pack must use.

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
TESTING
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Before declaring the plugin complete, verify the code logically for:

[ ] Compiles with Maven
[ ] Paper 1.21.11 compatibility
[ ] Java 21
[ ] Plugin loads without errors
[ ] Exactly 5 weapons
[ ] Correct PDC IDs
[ ] Correct model identifiers
[ ] Correct damage
[ ] Correct cooldowns
[ ] Correct reach
[ ] Correct durability
[ ] All 5 abilities work
[ ] Recipes work
[ ] Recipe editor works
[ ] Recipe persistence works
[ ] OP restrictions work
[ ] Permissions work
[ ] Tab completion works
[ ] No item duplication
[ ] No cooldown bypass
[ ] No projectile duplication
[ ] No major performance issues
[ ] Geyser optional
[ ] Floodgate optional
[ ] ViaVersion optional
[ ] ViaBackwards optional
[ ] WorldGuard optional
[ ] Grim-compatible movement
[ ] No anti-cheat bypass techniques

โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
CRITICAL OUTPUT RULE
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Generate the COMPLETE PLUGIN PROJECT.

Do NOT only explain how to make it.

Do NOT give pseudocode.

Do NOT leave TODOs.

Do NOT write placeholder methods such as:

// implement later

Actually implement every required system.

For every file, provide:

FILE: exact/path/to/file

followed by the COMPLETE contents.

The project must be internally consistent:
- class names match
- packages match
- imports match
- plugin.yml matches the main class
- commands match the command executor
- configuration paths match Java code
- weapon IDs match everywhere
- model identifiers match everywhere

Do NOT create the resource pack in this stage.

The resource pack will be created separately after the plugin is finished.

At the end, provide:
1. Build command
2. Output JAR location
3. Installation instructions
4. All commands
5. All permissions
6. Weapon IDs
7. Model identifiers
8. Exact information I need to use when creating the resource pack later

MOST IMPORTANT:
Build this specifically for Paper Minecraft 1.21.11, not an older Minecraft version. Verify every API you use against the 1.21.11 Paper API and avoid outdated 1.8/1.12/1.20 tutorials and APIs.
```
Kodari AI
KodariAug 29 at 2:34 pm 4
LagBrosWeapons
Creates a modular Paper plugin for Minecraft 1.21.11 featuring five custom weapons with unique abilities, custom durability, and configurable stats. Implements a PDC-based identification system separating gameplay identity from visual model identifiers for future resource pack integration. Includes a recipe editor GUI, cooldown management, reach bonuses, and optional compatibility hooks for ViaVersion, Geyser, Floodgate, WorldGuard, and Grim Anticheat. All weapons, abilities, damage values, and cooldowns are configurable via YAML files, with commands and permissions for administration.
  1. Create the Maven Paper 1.21.11 project and configuration files.

  2. Add weapon identity, custom durability, item-model, cooldown, combat, and ability systems.

  3. Add projectile handling, recipe persistence/editor GUI, commands, permissions, and optional WorldGuard checks.

  4. Add documentation covering installation, commands, mechanics, compatibility, and future resource-pack mapping.

The core project is generated. Iโ€™m tightening the combat path so ranged shots and reach validation use the same authoritative weapon data, while keeping the implementation server-side and bounded.1. Created a complete Maven Paper 1.21.11 / Java 21 project for LagBrosWeapons. 2. Added exactly five configurable weapons with PDC identity, custom durability, item-model identifiers, cooldowns, combat handling, and abilities. 3. Added bounded server-side ability mechanics, projectile cleanup, optional reflective WorldGuard protection checks, and optional-plugin-safe startup. 4. Added crafting recipes, persistent recipes.yml storage, recipe GUI controls, commands, permissions, and tab completion. 5. Added comprehensive README documentation, including future resource-pack model identifiers and compatibility notes.

Build:

Shell
mvn clean package

Output:

Plain Text
target/LagBrosWeapons.jar

Important implementation details:

  • Weapon identity uses:

    • lagbrosweapons:weapon_id

    • lagbrosweapons:weapon_version

    • lagbrosweapons:durability

  • Resource-pack model identifiers:

    • lagbrosweapons:zephyrs_edge

    • lagbrosweapons:cinderstrike

    • lagbrosweapons:tidecallers_harpoon

    • lagbrosweapons:abyssal_impaler

    • lagbrosweapons:eclipse_longbow

  • Optional integrations do not prevent startup when absent.

  • No NMS, packet spoofing, exploit mechanics, or anti-cheat bypasses were used.

  • No resource-pack files were created.

Kodari can make mistakes. Review important code before using.
Files
src
pom.xml
README.md
Code
33 1,191
src/main/java/com/lagbros/weapons/LagBrosWeapons.java
package com.lagbros.weapons;

import com.lagbros.weapons.ability.AbilityManager;
import com.lagbros.weapons.command.WeaponsCommand;
import com.lagbros.weapons.command.WeaponsTabCompleter;
import com.lagbros.weapons.combat.CooldownManager;
import com.lagbros.weapons.combat.DamageManager;
import com.lagbros.weapons.compatibility.WorldGuardHook;
import com.lagbros.weapons.listener.PlayerJoinListener;
import com.lagbros.weapons.listener.ProjectileListener;
import com.lagbros.weapons.listener.WeaponDamageListener;
import com.lagbros.weapons.listener.WeaponInteractListener;
import com.lagbros.weapons.recipe.RecipeEditor;
import com.lagbros.weapons.recipe.RecipeManager;
import com.lagbros.weapons.weapon.WeaponManager;
import net.kyori.adventure.text.Component;
import net.kyori.adventure.text.minimessage.MiniMessage;
import org.bukkit.Bukkit;
import org.bukkit.command.PluginCommand;
import org.bukkit.plugin.java.JavaPlugin;

public final class LagBrosWeapons extends JavaPlugin {
    private WeaponManager weaponManager;
    private CooldownManager cooldownManager;
    private DamageManager damageManager;
    private WorldGuardHook worldGuardHook;
    private RecipeManager recipeManager;
    private AbilityManager abilityManager;

    @Override
    public void onEnable() {
        saveDefaultConfig();
        saveResource("weapons.yml", false);
        saveResource("recipes.yml", false);
        saveResource("messages.yml", false);
        cooldownManager = new CooldownManager();
        worldGuardHook = new WorldGuardHook(this);
        weaponManager = new WeaponManager(this);
        weaponManager.reload();
        damageManager = new DamageManager(this, cooldownManager);
        abilityManager = new AbilityManager(this, cooldownManager, worldGuardHook);
        recipeManager = new RecipeManager(this, weaponManager);
        recipeManager.reload();
        RecipeEditor recipeEditor = new RecipeEditor(this, recipeManager);
        Bukkit.getPluginManager().registerEvents(new WeaponDamageListener(this), this);
        Bukkit.getPluginManager().registerEvents(new WeaponInteractListener(this), this);
        Bukkit.getPluginManager().registerEvents(new ProjectileListener(this), this);
        Bukkit.getPluginManager().registerEvents(new PlayerJoinListener(this), this);
        Bukkit.getPluginManager().registerEvents(recipeEditor, this);
        PluginCommand command = getCommand("weapons");
        if (command != null) {
            command.setExecutor(new WeaponsCommand(this));
            command.setTabCompleter(new WeaponsTabCompleter(this));
        }
        getLogger().info("Loaded " + weaponManager.getWeapons().size() + " weapons.");
        getLogger().info("Optional integrations: WorldGuard=" + worldGuardHook.isAvailable()
                + ", ViaVersion=" + hasPlugin("ViaVersion") + ", Geyser=" + hasPlugin("Geyser-Spigot"));
    }

    public void reloadPlugin() {
        reloadConfig();
        weaponManager.reload();
        recipeManager.reload();
    }

    public Component message(String path) {
        String prefix = getConfig().getString("messages-prefix", "");
        return MiniMessage.miniMessage().deserialize(prefix + path);
    }

    public Component text(String value) {
        return MiniMessage.miniMessage().deserialize(value == null ? "" : value);
    }

    public boolean hasPlugin(String name) {
        return Bukkit.getPluginManager().getPlugin(name) != null;
    }

    public WeaponManager getWeaponManager() { return weaponManager; }
    public CooldownManager getCooldownManager() { return cooldownManager; }
    public DamageManager getDamageManager() { return damageManager; }
    public WorldGuardHook getWorldGuardHook() { return worldGuardHook; }
    public RecipeManager getRecipeManager() { return recipeManager; }
    public AbilityManager getAbilityManager() { return abilityManager; }
}