papermc-skill 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/README.md +90 -110
  3. package/assets/banner-animated.svg +360 -0
  4. package/assets/banner.svg +360 -0
  5. package/bin/cli.js +199 -0
  6. package/docs/01-modern-paper-architecture.md +48 -51
  7. package/docs/02-adventure-and-minimessage.md +48 -52
  8. package/docs/03-persistent-data-container.md +39 -39
  9. package/docs/04-commands-and-brigadier.md +32 -35
  10. package/docs/05-concurrency-and-folia.md +44 -44
  11. package/docs/06-events-and-listeners.md +30 -31
  12. package/docs/07-best-practices-and-perf.md +39 -40
  13. package/docs/08-gui-and-menus.md +34 -37
  14. package/docs/09-custom-items-and-combat.md +25 -33
  15. package/docs/10-database-and-storage.md +27 -27
  16. package/docs/11-security-and-exploit-prevention.md +233 -0
  17. package/package.json +2 -1
  18. package/skills/paper-plugin-dev/SKILL.md +391 -111
  19. package/templates/paper-modern-template/.gradle/9.7.1/checksums/checksums.lock +0 -0
  20. package/templates/paper-modern-template/.gradle/9.7.1/checksums/md5-checksums.bin +0 -0
  21. package/templates/paper-modern-template/.gradle/9.7.1/checksums/sha1-checksums.bin +0 -0
  22. package/templates/paper-modern-template/.gradle/{9.4.1 → 9.7.1}/executionHistory/executionHistory.bin +0 -0
  23. package/templates/paper-modern-template/.gradle/9.7.1/executionHistory/executionHistory.lock +0 -0
  24. package/templates/paper-modern-template/.gradle/{9.4.1 → 9.7.1}/fileHashes/fileHashes.bin +0 -0
  25. package/templates/paper-modern-template/.gradle/9.7.1/fileHashes/fileHashes.lock +0 -0
  26. package/templates/paper-modern-template/.gradle/{9.4.1 → 9.7.1}/fileHashes/resourceHashesCache.bin +0 -0
  27. package/templates/paper-modern-template/.gradle/{9.4.1/checksums/md5-checksums.bin → 9.7.1/kotlin-dsl-plugin-entries/jar-entries.bin} +0 -0
  28. package/templates/paper-modern-template/.gradle/9.7.1/kotlin-dsl-plugin-entries/kotlin-dsl-plugin-entries.lock +0 -0
  29. package/templates/paper-modern-template/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  30. package/templates/paper-modern-template/.gradle/buildOutputCleanup/cache.properties +2 -2
  31. package/templates/paper-modern-template/build/classes/java/main/com/example/paperplugin/ExamplePaperPlugin.class +0 -0
  32. package/templates/paper-modern-template/build/classes/java/main/com/example/paperplugin/PaperPluginBootstrap.class +0 -0
  33. package/templates/paper-modern-template/build/classes/java/main/com/example/paperplugin/command/HelloCommand.class +0 -0
  34. package/templates/paper-modern-template/build/classes/java/main/com/example/paperplugin/listener/PlayerEventListener.class +0 -0
  35. package/templates/paper-modern-template/build/classes/java/main/com/example/paperplugin/util/SchedulerAdapter.class +0 -0
  36. package/templates/paper-modern-template/build/tmp/compileJava/previous-compilation-data.bin +0 -0
  37. package/templates/paper-modern-template/build.gradle.kts +10 -10
  38. package/templates/paper-modern-template/gradle/wrapper/gradle-wrapper.jar +0 -0
  39. package/templates/paper-modern-template/gradle/wrapper/gradle-wrapper.properties +1 -1
  40. package/templates/paper-modern-template/gradlew +3 -3
  41. package/templates/paper-modern-template/gradlew.bat +12 -23
  42. package/templates/paper-modern-template/settings.gradle.kts +7 -0
  43. package/templates/paper-modern-template/src/main/java/com/example/paperplugin/ExamplePaperPlugin.java +6 -6
  44. package/templates/paper-modern-template/src/main/java/com/example/paperplugin/PaperPluginBootstrap.java +2 -2
  45. package/templates/paper-modern-template/src/main/java/com/example/paperplugin/command/HelloCommand.java +2 -4
  46. package/templates/paper-modern-template/src/main/java/com/example/paperplugin/data/PluginDataKeys.java +2 -2
  47. package/templates/paper-modern-template/src/main/java/com/example/paperplugin/listener/PlayerEventListener.java +6 -7
  48. package/templates/paper-modern-template/src/main/java/com/example/paperplugin/util/SchedulerAdapter.java +6 -6
  49. package/templates/paper-modern-template/src/main/resources/config.yml +5 -5
  50. package/templates/paper-modern-template/.gradle/9.4.1/checksums/checksums.lock +0 -0
  51. package/templates/paper-modern-template/.gradle/9.4.1/checksums/sha1-checksums.bin +0 -0
  52. package/templates/paper-modern-template/.gradle/9.4.1/executionHistory/executionHistory.lock +0 -0
  53. package/templates/paper-modern-template/.gradle/9.4.1/fileHashes/fileHashes.lock +0 -0
  54. package/templates/paper-modern-template/.gradle/file-system.probe +0 -0
  55. /package/templates/paper-modern-template/.gradle/{9.4.1 → 9.7.1}/fileChanges/last-build.bin +0 -0
  56. /package/templates/paper-modern-template/.gradle/{9.4.1 → 9.7.1}/gc.properties +0 -0
package/CHANGELOG.md CHANGED
@@ -5,6 +5,47 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.1.0] - 2026-10-01
9
+
10
+ ### Added
11
+ - **Plugin Security & Anti-Exploit Scanner CLI (`npx papermc-skill audit [path]`)**:
12
+ - Scans Java sources for known Bukkit/Paper vulnerabilities including legacy ChatColor usage, section sign formatting bugs, static collection memory leaks (`Set<Player>`), synchronous chunk freezes (`world.getChunkAt`), insecure SQL string concatenation, and unbounded float/double parsing.
13
+ - **Masterclass Guide 11: Security & Exploit Prevention (`docs/11-security-and-exploit-prevention.md`)**:
14
+ - Deep-dive architectural guide covering item dupe glitch elimination, inventory race conditions, PDC cryptographic tamper-proofing, numeric/economy validation (anti-NaN/overflow), asynchronous chunk loading teleportation, HikariCP connection leak prevention, and memory leak elimination.
15
+ - **Massively Enriched AI Agent Skill (`skills/paper-plugin-dev/SKILL.md`)**:
16
+ - Added dedicated Security & Exploit-Proofing protocol.
17
+ - Added production recipes for Secure Brigadier Commands with numeric bounds, Safe GUI Menu Controllers with 200ms click debounce and drag cancellation, Anti-Tamper PDC Item Utilities, Universal Folia/Paper Schedulers, and Async HikariCP Database Managers.
18
+ - Added 20-point Pre-Release Security Audit Checklist.
19
+
20
+ ### Changed
21
+ - **SchedulerAdapter Precision Hardening**:
22
+ - Fixed tick conversion in `SchedulerAdapter.java` to use exact millisecond calculation `timeUnit.toMillis(delay) / 50L`.
23
+ - **Documentation & Distribution**:
24
+ - Added `assets/` to package distribution files for local and offline tooling.
25
+ - Updated README documentation with Guide 11 and audit quickstart command.
26
+
27
+ ## [1.0.1] - 2026-09-15
28
+
29
+ ### Added
30
+ - **PaperMC Fill v3 API Dynamic Version Tracker**:
31
+ - New CLI command `npx papermc-skill check-update [--apply]` to query `https://fill.papermc.io/v3/projects/paper` for the newest Minecraft & PaperMC versions, builds, and minimum Java requirements.
32
+ - Automated GitHub Actions workflow (`.github/workflows/paper-updater.yml`) running weekly or on-demand to test and bump Paper versions automatically via Pull Requests.
33
+ - Dependabot configuration (`.github/dependabot.yml`) for automated dependency monitoring across Gradle, GitHub Actions, and npm.
34
+ - Dynamic Version Discovery protocol in AI Agent skill (`skills/paper-plugin-dev/SKILL.md`).
35
+ - **Gaming & Hype Aesthetic Overhaul**:
36
+ - Retro ASCII Art header banner, badges, and high-energy developer quotes in `README.md` and GitHub Release notes.
37
+
38
+ ### Changed
39
+ - **Dependency Upgrades**:
40
+ - Bumped `io.papermc.paper:paper-api` from `1.21.4` to latest Minecraft 1.21 LTS release `1.21.11-R0.1-SNAPSHOT`.
41
+ - Bumped Gradle Wrapper from `9.4.1` to `9.7.1`.
42
+ - Bumped `xyz.jpenilla.run-paper` from `3.0.2` to `3.1.0`.
43
+ - Bumped `org.jspecify` from `1.0.0` to `1.0.1`.
44
+ - Upgraded GitHub Actions to latest major versions (`actions/checkout@v7`, `actions/setup-java@v6`, `actions/setup-node@v7`, `softprops/action-gh-release@v3`, `peter-evans/create-pull-request@v8`).
45
+ - **Build Stabilization**:
46
+ - Added `pluginManagement` with `mavenCentral()` to `settings.gradle.kts` for reliable Gradle plugin dependency resolution.
47
+ - Configured Dependabot ignore rules to keep `paper-api` on Java 21 LTS compatibility.
48
+
8
49
  ## [1.0.0] - 2026-09-05
9
50
 
10
51
  ### Added
package/README.md CHANGED
@@ -1,169 +1,149 @@
1
1
  <div align="center">
2
2
 
3
- # 🎮 Paper Minecraft Plugin Skill & Knowledge Base
3
+ <a href="https://github.com/ardianryan/papermc-skill">
4
+ <img src="https://raw.githubusercontent.com/ardianryan/papermc-skill/main/assets/banner-animated.svg" alt="PaperMC Skill - The Ultimate Paper &amp; Folia Arsenal" width="100%" />
5
+ </a>
6
+
7
+ # ⚔️ PAPERMC PLUGIN SKILL & KNOWLEDGE BASE ⚔️
8
+
9
+ **Stop writing legacy Spigot code like it's 2014. Build for modern Paper & Folia with pure speed, thread-safety, and zero lag.**
4
10
 
5
11
  [![PaperMC](https://img.shields.io/badge/PaperMC-1.20.6%20%7C%201.21+-0098FF?style=for-the-badge&logo=minecraft&logoColor=white)](https://papermc.io)
12
+ [![Folia](https://img.shields.io/badge/Folia-Multi--Threaded%20Ready-5865F2?style=for-the-badge&logo=dependabot&logoColor=white)](https://github.com/PaperMC/Folia)
6
13
  [![Java](https://img.shields.io/badge/Java-21%2B%20LTS-ED8B00?style=for-the-badge&logo=openjdk&logoColor=white)](https://adoptium.net)
7
- [![Folia](https://img.shields.io/badge/Folia-Multi--Threaded%20Ready-5865F2?style=for-the-badge)](https://github.com/PaperMC/Folia)
14
+ [![NPM](https://img.shields.io/npm/v/papermc-skill?style=for-the-badge&color=CB3837&logo=npm&logoColor=white)](https://www.npmjs.com/package/papermc-skill)
15
+ [![GitHub Release](https://img.shields.io/github/v/release/ardianryan/papermc-skill?style=for-the-badge&color=2ea44f&logo=github&logoColor=white)](https://github.com/ardianryan/papermc-skill/releases/latest)
8
16
  [![License: MIT](https://img.shields.io/badge/License-MIT-44CC11?style=for-the-badge)](LICENSE)
9
- [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen?style=for-the-badge)](CONTRIBUTING.md)
10
17
 
11
- **A comprehensive, production-grade knowledge base, architectural reference collection, starter template, and AI engineering skill for modern Minecraft Java Server plugin development on [PaperMC](https://papermc.io) and [Folia](https://github.com/PaperMC/Folia).**
12
-
13
- [Features](#-features) • [Quickstart](#-quickstart) • [Architecture Guide](#-documentation-suite) • [Reference Plugins](#-cloned-reference-plugins) • [AI Skill](#-ai-agent-integration) • [Contributing](#-contributing)
18
+ [⚡ Quickstart](#-instant-quickstart-5-seconds) • [💎 Key Features](#-why-modern-paper-matters) • [📚 11 Masterclass Guides](#-11-masterclass-technical-guides) • [🔍 Battle-Tested References](#-cloned-reference-plugins) • [🤖 AI Agent Skill](#-ai-agent-integration)
14
19
 
15
20
  ---
16
21
 
17
22
  </div>
18
23
 
19
- ## 🌟 Overview
24
+ ## 🚀 Instant Quickstart (5 Seconds!)
20
25
 
21
- The Minecraft server development ecosystem has undergone massive architectural shifts with Minecraft 1.20.5+ and 1.21+. Legacy Bukkit/Spigot habits—such as section sign color formatting (`§`), `plugin.yml` command registration, third-party NBT hacks, and blocking main-thread schedulers—lead to performance degradation, memory leaks, and fatal crashes on modern servers.
26
+ You don't need to configure Gradle or clone anything manually. Scaffold a production-grade, Folia-ready Paper plugin right now with **one command**:
22
27
 
23
- This repository serves as an **authoritative, single-source knowledge base** and **developer skill** designed to empower both human software engineers and AI pair-programming assistants to build performant, thread-safe, and idiomatic Paper plugins.
28
+ ```bash
29
+ npx papermc-skill create MyEpicPlugin
30
+ ```
24
31
 
25
- ---
32
+ Or install the AI skill globally so your coding agents (**Antigravity**, **Cursor**, **Copilot**) write flawless Paper 1.21+ code:
26
33
 
27
- ## ⚡ Key Architecture Highlights
34
+ ```bash
35
+ npx papermc-skill install-skill --global
36
+ ```
28
37
 
29
- | Modern Paper Standard | Legacy Spigot / Bukkit | Why Modern Matters |
30
- | :--- | :--- | :--- |
31
- | **Kyori Adventure & MiniMessage** | `ChatColor` & `§` color codes | Type-safe, component-based, 24-bit TrueColor/Hex gradients, interactive click/hover events, and zero string-injection risks. |
32
- | **PersistentDataContainer (PDC)** | External NBT libraries / Lore parsing | Official native NBT storage on Items, Entities, Chunks, and Worlds. Serializes Java records seamlessly. |
33
- | **Paper Native Brigadier** | `plugin.yml` & `setExecutor(...)` | Client-side syntax validation, auto tab-completion, and command routing directly inside Mojang's Brigadier engine. |
34
- | **Regionized Threading (Folia)** | Single Main Thread `BukkitScheduler` | Scales across CPU cores via Threaded Regions. Uses `RegionScheduler`, `EntityScheduler`, and `AsyncScheduler`. |
35
- | **Mojang Mappings (Paperweight)** | Spigot remapped / Obfuscated NMS | Zero-remapping runtime on Paper 1.20.5+; direct, clean access to Mojang server internals with `paperweight-userdev`. |
38
+ To browse architectural cheat sheets directly in your terminal:
39
+ ```bash
40
+ npx papermc-skill docs
41
+ ```
36
42
 
37
- ---
43
+ To check for the newest Minecraft & PaperMC releases from the official API:
44
+ ```bash
45
+ npx papermc-skill check-update
46
+ ```
38
47
 
39
- ## 📚 Documentation Suite
40
-
41
- Our documentation suite includes 10 comprehensive, in-depth architectural guides:
42
-
43
- 1. **[01. Modern Paper Architecture](https://github.com/ardianryan/papermc-skill/blob/main/docs/01-modern-paper-architecture.md)**
44
- *Deep dive into `paper-plugin.yml`, `PluginBootstrap` vs `JavaPlugin`, Gradle `paperweight-userdev`, and runtime Mojang mappings.*
45
- 2. **[02. Adventure API & MiniMessage](https://github.com/ardianryan/papermc-skill/blob/main/docs/02-adventure-and-minimessage.md)**
46
- *Hex colors, gradient tags, dynamic `TagResolver` placeholders, `ComponentLogger`, Titles, BossBars, and Sound playback.*
47
- 3. **[03. PersistentDataContainer (PDC)](https://github.com/ardianryan/papermc-skill/blob/main/docs/03-persistent-data-container.md)**
48
- *Storing custom data on ItemStacks, Entities, and Chunks; implementing custom `PersistentDataType<T, Z>` for POJO/record serialization.*
49
- 4. **[04. Modern Command Systems: Brigadier & Cloud](https://github.com/ardianryan/papermc-skill/blob/main/docs/04-commands-and-brigadier.md)**
50
- *Paper's native Brigadier command registration via `LifecycleEvents.COMMANDS`, argument parsing, suggestions, and Incendo Cloud.*
51
- 5. **[05. Concurrency, Threading & Folia Compatibility](https://github.com/ardianryan/papermc-skill/blob/main/docs/05-concurrency-and-folia.md)**
52
- *Threaded regions, region schedulers, entity schedulers, async schedulers, and universal cross-platform scheduling abstractions.*
53
- 6. **[06. Event System & Listeners](https://github.com/ardianryan/papermc-skill/blob/main/docs/06-events-and-listeners.md)**
54
- *Paper-exclusive events (`AsyncChatEvent`, `PrePlayerAttackEntityEvent`), event priority lifecycle, and custom event authoring.*
55
- 7. **[07. Best Practices & Performance Optimization](https://github.com/ardianryan/papermc-skill/blob/main/docs/07-best-practices-and-perf.md)**
56
- *Preventing GC memory leaks (UUID vs entity references), asynchronous chunk loading (`world.getChunkAtAsync`), and anti-patterns.*
57
- 8. **[08. Modern GUI & Inventory Menus](https://github.com/ardianryan/papermc-skill/blob/main/docs/08-gui-and-menus.md)**
58
- *Custom `InventoryHolder` verification, PDC-tagged interactive buttons, and bulletproof duplication-exploit prevention.*
59
- 9. **[09. Custom Items, Abilities & Combat](https://github.com/ardianryan/papermc-skill/blob/main/docs/09-custom-items-and-combat.md)**
60
- *Raycasting hitscan spells (`rayTraceEntities`), particle beam effects, vanilla visual cooldowns, and Adventure sound effects.*
61
- 10. **[10. Asynchronous Database Storage](https://github.com/ardianryan/papermc-skill/blob/main/docs/10-database-and-storage.md)**
62
- *SQLite and MySQL/PostgreSQL connection pooling via HikariCP, thread-safe asynchronous DAO pattern with `CompletableFuture`.*
48
+ To audit any plugin codebase for exploits, memory leaks, and anti-patterns:
49
+ ```bash
50
+ npx papermc-skill audit
51
+ ```
63
52
 
64
53
  ---
65
54
 
66
- ## 🔍 Cloned Reference Plugins
55
+ ## 💎 Why Modern Paper Matters
67
56
 
68
- Nine industry-standard open-source repositories have been cloned into [`references/`](references/) as real-world architectural blueprints:
57
+ The Minecraft server ecosystem has evolved dramatically. Legacy habits lead to server lag spikes, thread collisions, and fatal crashes on modern engines:
69
58
 
70
- | Repository | Source Origin | Core Concepts Demonstrated |
59
+ | Feature | 💀 Legacy Spigot / Bukkit | ⚡ Modern Paper & Folia (1.20.6 / 1.21+) |
71
60
  | :--- | :--- | :--- |
72
- | **[`squaremap`](references/squaremap)** | `jpenilla/squaremap` | Developed by a PaperMC core developer. World rendering, `paperweight-userdev`, Incendo Cloud commands, and Folia multi-threading. |
73
- | **[`chunky`](references/chunky)** | `pop4959/Chunky` | High-throughput async chunk loading (`world.getChunkAtAsync`), mathematical optimizations, and multi-platform platform adapters. |
74
- | **[`luckperms`](references/luckperms)** | `LuckPerms/LuckPerms` | Enterprise-grade Java architecture: HikariCP connection pooling, custom internal event bus, caching hierarchy, and async I/O. |
75
- | **[`miniplaceholders`](references/miniplaceholders)** | `MiniPlaceholders/MiniPlaceholders` | Advanced Kyori Adventure API usage, custom MiniMessage tag resolvers, and modern `paper-plugin.yml` bootstrapping. |
76
- | **[`vault-api`](references/vault-api)** | `MilkBowl/VaultAPI` | The standard ecosystem bridge API for economy and permissions in Minecraft Java. |
77
- | **[`run-paper`](references/run-paper)** | `jpenilla/run-paper` | The Gradle plugin source code for running instant local Paper and Folia test environments. |
78
- | **[`decentholograms`](references/decentholograms)** | `DecentSoftware-eu/DecentHolograms` | Display entity manipulation, protocol packet handling, and dynamic per-player text rendering. |
79
- | **[`bstats`](references/bstats)** | `Bastian/bStats-Metrics` | Industry-standard telemetry and metrics integration for Minecraft server plugins. |
80
- | **[`paperweight-test-plugin`](references/paperweight-test-plugin)** | `PaperMC/paperweight-test-plugin` | Official PaperMC test project for `paperweight-userdev` Gradle configurations. |
61
+ | **Color & Text** | `ChatColor.RED + "§lText"` | **Kyori Adventure & MiniMessage**: `<gradient:#ff007f:#7f00ff><bold>Text</bold></gradient>` |
62
+ | **Persistent Data** | Third-party NBT hacks / Lore reading | **PersistentDataContainer (PDC)**: Native, type-safe NBT on Items, Entities, Chunks, and Worlds. |
63
+ | **Command System** | `plugin.yml` + `setExecutor(...)` | **Paper Native Brigadier**: Client-side syntax validation, auto tab-completion directly in Mojang's engine. |
64
+ | **Multi-Threading** | Single main thread (`BukkitScheduler`) | **Threaded Regions (Folia)**: Independent regional ticking via `RegionScheduler` & `EntityScheduler`. |
65
+ | **Server Internals** | Obfuscated Spigot remapping | **Paperweight Userdev**: Direct, unmapped access to Mojang Mappings (`net.minecraft.*`) at runtime. |
81
66
 
82
67
  ---
83
68
 
84
- ## 🚀 Quickstart
69
+ ## 📚 11 Masterclass Technical Guides
85
70
 
86
- ### Method 1: Instant Scaffolding via NPX (Recommended)
71
+ Written by developers for developers, covering everything from basic setup to high-throughput concurrency:
87
72
 
88
- You can scaffold a new Paper plugin or install the AI skill instantly anywhere using `npx`:
73
+ | # | Masterclass Guide | Focus & Highlights |
74
+ | :-: | :--- | :--- |
75
+ | **01** | [Modern Paper Architecture](https://github.com/ardianryan/papermc-skill/blob/main/docs/01-modern-paper-architecture.md) | `paper-plugin.yml`, `PluginBootstrap` vs `JavaPlugin`, Gradle `paperweight-userdev`, and runtime Mojang mappings. |
76
+ | **02** | [Adventure API & MiniMessage](https://github.com/ardianryan/papermc-skill/blob/main/docs/02-adventure-and-minimessage.md) | Hex gradients, dynamic `TagResolver` placeholders, `ComponentLogger`, Titles, BossBars, and Sound playback. |
77
+ | **03** | [PersistentDataContainer (PDC)](https://github.com/ardianryan/papermc-skill/blob/main/docs/03-persistent-data-container.md) | Custom NBT on ItemStacks, Entities, and Chunks; implementing custom `PersistentDataType<T, Z>` for Java records. |
78
+ | **04** | [Modern Brigadier & Cloud Commands](https://github.com/ardianryan/papermc-skill/blob/main/docs/04-commands-and-brigadier.md) | Native Mojang Brigadier trees via `LifecycleEvents.COMMANDS`, argument suggestions, and Incendo Cloud. |
79
+ | **05** | [Concurrency & Folia Compatibility](https://github.com/ardianryan/papermc-skill/blob/main/docs/05-concurrency-and-folia.md) | Threaded regions, region schedulers, entity schedulers, async schedulers, and universal platform wrappers. |
80
+ | **06** | [Event System & Paper Listeners](https://github.com/ardianryan/papermc-skill/blob/main/docs/06-events-and-listeners.md) | Paper-exclusive events (`AsyncChatEvent`, `PrePlayerAttackEntityEvent`), event priority, and custom events. |
81
+ | **07** | [Best Practices & Performance Tuning](https://github.com/ardianryan/papermc-skill/blob/main/docs/07-best-practices-and-perf.md) | Eliminating GC memory leaks (UUID vs entity references), asynchronous chunk loading (`world.getChunkAtAsync`). |
82
+ | **08** | [Modern GUI & Inventory Menus](https://github.com/ardianryan/papermc-skill/blob/main/docs/08-gui-and-menus.md) | Custom `InventoryHolder` menus, PDC interactive buttons, and bulletproof duplication-exploit prevention. |
83
+ | **09** | [Custom Items, Abilities & Combat](https://github.com/ardianryan/papermc-skill/blob/main/docs/09-custom-items-and-combat.md) | Raycasting spells (`rayTraceEntities`), particle beam effects, vanilla visual cooldowns, and SFX. |
84
+ | **10** | [Asynchronous Database Storage](https://github.com/ardianryan/papermc-skill/blob/main/docs/10-database-and-storage.md) | SQLite & MySQL HikariCP connection pooling, thread-safe asynchronous DAO pattern with `CompletableFuture`. |
85
+ | **11** | [Security & Exploit Prevention](https://github.com/ardianryan/papermc-skill/blob/main/docs/11-security-and-exploit-prevention.md) | Eliminating dupe glitches, inventory race conditions, PDC tamper verification, numeric/economy validation, and packet DoS defense. |
89
86
 
90
- ```bash
91
- # 1. Interactively create a new modern Paper & Folia plugin
92
- npx papermc-skill create MyAwesomePlugin
87
+ ---
93
88
 
94
- # 2. Or install the AI skill into your workspace (.agents/skills) or globally
95
- npx papermc-skill install-skill --global
89
+ ## 🏛️ Cloned Reference Plugins
96
90
 
97
- # 3. Read architectural guides right in your terminal
98
- npx papermc-skill docs
99
- ```
91
+ Nine battle-tested open-source repositories are included directly in [`references/`](references/) for reverse-engineering and architectural inspiration:
92
+
93
+ - 🗺️ **[`squaremap`](references/squaremap)**: Production Paperweight, Incendo Cloud commands, and Folia multi-threading by PaperMC core dev `jpenilla`.
94
+ - ⚡ **[`chunky`](references/chunky)**: High-throughput async chunk generation engine (`world.getChunkAtAsync`) and multi-platform abstractions.
95
+ - 🛡️ **[`luckperms`](references/luckperms)**: Enterprise permissions, HikariCP database pool, caching hierarchy, and custom event bus.
96
+ - 🏷️ **[`miniplaceholders`](references/miniplaceholders)**: Advanced Kyori Adventure API and custom MiniMessage tag resolvers.
97
+ - 💰 **[`vault-api`](references/vault-api)**: The industry-standard economy and permissions bridge API.
98
+ - 🛠️ **[`run-paper`](references/run-paper)**: The instant local Paper/Folia runner Gradle plugin.
99
+ - 👻 **[`decentholograms`](references/decentholograms)**: Protocol display entity manipulation, floating text, and packet optimizations.
100
+ - 📊 **[`bstats`](references/bstats)**: Global plugin telemetry and metrics integration.
101
+ - 🧪 **[`paperweight-test-plugin`](references/paperweight-test-plugin)**: Official PaperMC Mojang mapping testbed.
100
102
 
101
- ### Method 2: Manual Clone & Local Server Test
103
+ ---
102
104
 
103
- A production-ready Gradle starter template is available in [`templates/paper-modern-template/`](templates/paper-modern-template).
105
+ ## 🛠️ Runnable Starter Template
104
106
 
105
- #### Prerequisites
106
- - **Java 21 SDK** installed ([Adoptium Temurin 21](https://adoptium.net/)):
107
- - macOS: `brew install openjdk@21`
108
- - Linux: `sudo apt install openjdk-21-jdk`
109
- - Gradle is bundled inside the template via `./gradlew` (no manual Gradle install required).
107
+ A battle-ready project is pre-configured in [`templates/paper-modern-template/`](templates/paper-modern-template):
110
108
 
111
- #### Running a Local Test Server in 60 Seconds
112
109
  ```bash
113
- # 1. Navigate to the template project
110
+ # Navigate to the template
114
111
  cd templates/paper-modern-template
115
112
 
116
- # 2. Launch an automated Paper test server
113
+ # Launch an automated Paper test server in 60s
117
114
  ./gradlew runServer
118
115
 
119
- # 3. Or launch a multi-threaded Folia test server
116
+ # Or launch on multi-threaded Folia
120
117
  ./gradlew runFoliaServer
121
118
  ```
122
- The task will automatically download the Paper/Folia runtime, accept the Mojang EULA, compile your code, and launch the server with your plugin enabled.
123
119
 
124
120
  ---
125
121
 
126
122
  ## 🤖 AI Agent Integration
127
123
 
128
- This repository includes a standardized AI Assistant Skill in [`skills/paper-plugin-dev/SKILL.md`](skills/paper-plugin-dev/SKILL.md).
124
+ This repository includes a machine-readable coding skill in [`skills/paper-plugin-dev/SKILL.md`](skills/paper-plugin-dev/SKILL.md).
129
125
 
130
- When working with AI coding assistants (such as Antigravity, GitHub Copilot, or Cursor):
131
- - Point your assistant to `skills/paper-plugin-dev/SKILL.md`.
132
- - The assistant will automatically adopt modern Paper 1.21+ standards, avoid deprecated Spigot methods, enforce Folia thread-safety, and use Adventure/PDC patterns out of the box.
126
+ When pair-programming with AI coding agents:
127
+ - Tell your agent: *"Use the `paper-plugin-dev` skill"*.
128
+ - The agent will automatically generate Folia-safe schedulers, MiniMessage components, Brigadier command trees, and PDC data holders with zero legacy anti-patterns.
133
129
 
134
130
  ---
135
131
 
136
- ## 📁 Repository Structure
137
-
138
- ```text
139
- minecraft-plugin-skill/
140
- ├── .github/ # Issue & Pull Request templates
141
- │ ├── ISSUE_TEMPLATE/
142
- │ │ ├── bug_report.yml
143
- │ │ └── feature_request.yml
144
- │ └── pull_request_template.md
145
- ├── docs/ # 10 In-depth architectural guides
146
- ├── references/ # 9 Cloned open-source reference plugins
147
- ├── skills/
148
- │ └── paper-plugin-dev/ # AI Assistant Skill definition (SKILL.md)
149
- ├── templates/
150
- │ └── paper-modern-template/ # Standalone, runnable starter plugin project
151
- ├── CODE_OF_CONDUCT.md # Contributor Covenant v2.1
152
- ├── CONTRIBUTING.md # Comprehensive contribution guide
153
- ├── LICENSE # MIT License
154
- ├── README.md # Repository documentation
155
- └── SECURITY.md # Security policy & reporting guidelines
156
- ```
132
+ ## 📦 Packages & Distribution
157
133
 
158
- ---
134
+ | Channel | Identifier / Command | Link |
135
+ | :--- | :--- | :--- |
136
+ | **NPM Global** | `npx papermc-skill` | [![NPM Version](https://img.shields.io/npm/v/papermc-skill?color=CB3837)](https://www.npmjs.com/package/papermc-skill) |
137
+ | **GitHub Packages** | `@ardianryan/papermc-skill` | [GitHub Packages Hub](https://github.com/users/ardianryan/packages?repo_name=papermc-skill) |
138
+ | **Release Asset** | `papermc-skill-v1.1.0.zip` | [Latest GitHub Release](https://github.com/ardianryan/papermc-skill/releases/latest) |
159
139
 
160
- ## 🤝 Contributing
140
+ ---
161
141
 
162
- Contributions are welcome! Please read our [Contributing Guidelines](CONTRIBUTING.md) and [Code of Conduct](CODE_OF_CONDUCT.md) before submitting pull requests or opening issues.
142
+ <div align="center">
163
143
 
164
- ---
144
+ ### 🌟 Show Your Support!
145
+ If this toolkit helped you or your server project, give this repository a **Star ⭐** on GitHub!
165
146
 
166
- ## 📄 License & Trademarks
147
+ *Minecraft is a registered trademark of Mojang Synergies AB. This project is not affiliated with or endorsed by Mojang Synergies AB, Microsoft Corporation, or PaperMC.*
167
148
 
168
- - This project is licensed under the **[MIT License](LICENSE)**.
169
- - *Minecraft* is a registered trademark of Mojang Synergies AB. This project is not affiliated with or endorsed by Mojang Synergies AB, Microsoft Corporation, or PaperMC.
149
+ </div>