Skip to content

Performance

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

Performance Breakdown

PixelRTPPool was engineered specifically for large, enterprise-grade Paper servers. Server owners often dread region-based plugins because they tend to destroy TPS (Ticks Per Second). We solved this.

Here is a technical overview of why PixelRTPPool is incredibly lightweight.

The PlayerMoveEvent Problem

Legacy plugins often rely on the Spigot PlayerMoveEvent to detect when a player enters an area.

  • This event fires dozens of times per second, per player.
  • If a server has 100 players moving their mice, jumping, or sprinting, the event fires thousands of times per second.
  • Iterating through a list of configured coordinates during every single one of those events results in massive CPU bottlenecking.

The WorldGuard SessionHandler Solution

PixelRTPPool completely abandons the PlayerMoveEvent.

Instead, it registers an asynchronous SessionHandler directly inside WorldGuard's core framework. WorldGuard is already highly optimized to calculate bounding boxes and chunk intersections via spatial hashes. When WorldGuard natively calculates that a player has crossed a region boundary, it quietly notifies PixelRTPPool.

This means our plugin does absolute zero mathematical boundary polling on the main server thread.

Memory Management

UUID Caching

Retaining Bukkit Player objects in memory lists (HashMaps, Arrays) after they disconnect is the #1 cause of plugin memory leaks. PixelRTPPool exclusively caches raw UUID strings. When data needs to be evaluated, it cross-references the UUID against the live server index.

Runnable Destruction

When a player enters a pool, a BukkitRunnable is scheduled to count down. These tasks are strictly cataloged inside the CountdownManager. The task is instantly destroyed and garbage collected if the player:

  • Disconnects
  • Dies
  • Leaves the region boundary
  • The server reloads

Reload Cleanup

When /rtppool reload is executed, the ConfigManager doesn't just read the YAML. It systematically shuts down the TeleportManager, flushes the RTPRegion caches, and cleanly instantiates fresh provider instances. This guarantees zero lingering threads or ghost configurations.


🏑 Home | πŸ“– Read Next: Architecture

πŸ“š PixelRTPPool Wiki

Welcome to the official documentation for PixelRTPPool.


πŸš€ Getting Started


🌊 RTP System


πŸ“– Usage


⚑ Technical


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


❓ Help


πŸ“Œ Project


πŸ”— External Links

Clone this wiki locally