Skip to content

Developer Guide

Parthiv Gamit edited this page Jul 8, 2026 · 1 revision

Developer Guide

Welcome to the PixelRTPPool developer documentation. If you intend to fork, contribute, or write an addon for this plugin, this guide covers the core expectations.

Building with Maven

The project relies entirely on Maven for dependency management and lifecycle builds.

Command:

mvn clean package

Note: We utilize the maven-shade-plugin to shade bStats into the final jar. The compiled output will be PixelRTPPool-1.0.0.jar in the target/ directory.

Project Structure

me.pixel.rtppool
β”œβ”€β”€ combat       # Combat tagger hooks and providers
β”œβ”€β”€ commands     # Command executors
β”œβ”€β”€ config       # YAML parsing and data modeling
β”œβ”€β”€ hooks        # Soft-depend external hooks (e.g., PlaceholderAPI)
β”œβ”€β”€ listeners    # Bukkit event listeners
β”œβ”€β”€ manager      # Central logic controllers (RTP, Cooldown, Countdown)
β”œβ”€β”€ model        # Immutable data classes (e.g., RTPRegion)
β”œβ”€β”€ region       # WorldGuard SessionHandlers
β”œβ”€β”€ tasks        # BukkitRunnables
β”œβ”€β”€ teleport     # Execution providers (PLAYER vs CONSOLE)
└── util         # Static utilities (Colors, Particles, Sounds)

Coding Standards

  • Java 21 Required: The project is compiled targeting JDK 21. Ensure your IDE is properly configured.
  • Paper API Only: We use the paper-api dependency. Do not use Spigot-exclusive API methods. Use Adventure API (MiniMessage) exclusively for text formatting; legacy ChatColor is strictly prohibited.
  • SRP (Single Responsibility Principle): Managers manage. Listeners listen. Do not write monolithic classes.
  • UUIDs Over Players: Never store org.bukkit.entity.Player in HashMaps or Lists.

Adding Providers

Adding a new TeleportProvider

If you wish to add a native integration for an external plugin (e.g., BetterRTP API instead of executing commands):

  1. Create a class implementing TeleportProvider.
  2. Implement the teleport(Player player, String commandTemplate) method.
  3. Hook it inside TeleportManager#setupProvider().

Adding a new CombatProvider

If you wish to integrate a combat tagger (e.g., CombatLogX):

  1. Create a class implementing CombatProvider.
  2. Implement boolean isInCombat(Player player).
  3. Hook it inside CombatManager during plugin initialization.

Versioning

This project strictly adheres to Semantic Versioning.

  • MAJOR version for incompatible API/Config changes.
  • MINOR version for adding functionality in a backwards compatible manner.
  • PATCH version for backwards compatible bug fixes.

🏑 Home | πŸ“– Read Next: FAQ

πŸ“š PixelRTPPool Wiki

Welcome to the official documentation for PixelRTPPool.


πŸš€ Getting Started


🌊 RTP System


πŸ“– Usage


⚑ Technical


πŸ‘¨β€πŸ’» Development


❓ Help


πŸ“Œ Project


πŸ”— External Links

Clone this wiki locally