Skip to main content

CannonRTP (WorldCannon)

CannonRTP is a multi-cannon random-teleportation plugin for Minecraft servers. "WorldCannon" is an older / wiki-section name; the plugin registers as CannonRTP in Bukkit, ships as CannonRTP.jar, and that is the name players and admins see.

Key naming details:

  • Plugin name: CannonRTP
  • Root command: /cannonrtp
  • Aliases: /crtp, /wc
  • Permissions: cannonrtp.admin, cannonrtp.use
  • Config folder: plugins/CannonRTP/

What It Does

CannonRTP is a multi-cannon random-landing system rather than a single fixed launcher. Each configured cannon can be placed at one or many locations in the world, and each placement watches for players walking into its trigger radius.

Each cannon can:

  • be placed multiple times via /wc create and /wc place -- a single cannon config drives every placement
  • watch for players entering a per-cannon trigger radius (default 1.75 blocks)
  • preload and maintain a queue of safe landing locations in a configured target world (cross-world targeting is supported)
  • reject unsafe terrain, blocked spaces, protected land, and locations outside the world border
  • optionally require an extra per-cannon permission
  • launch players through a five-phase cinematic sequence
  • display a FreeMinecraftModels 3D animated cannon (per-cannon customModel or via a global priority list); falls back to color-shifting orbit particles when FMM is not installed
  • show a billboarded floating status label above the cannon (Ready / Charging / Maintaining / Exhausted / Disabled / Invalid)

Launch Flow

The launch sequence is driven by a five-phase state machine (SEARCHING -> FIRING -> TELEPORTING -> DROPPING -> LANDING). When a player walks into an eligible cannon's trigger radius:

  1. CannonRTP checks cannonrtp.use.
  2. It checks the cannon's optional requiredPermission.
  3. It verifies the cannon is enabled, has a valid configuration, and has at least one preloaded landing location queued.
  4. It consumes one preloaded safe landing location from that cannon's queue.
  5. It fires CannonRTPLaunchEvent (cancellable). If a listener cancels it, the destination is returned to the queue and the cannon resumes normal behavior.
  6. Searching phase (default 42 ticks, configurable via launchWarmupTicks): the player gets Levitation, the cannon plays its fire animation if a custom model is active, and randomized coordinate previews flicker through title/subtitle. While a model is active the player also gets Invisibility so the animation reads cleanly.
  7. Firing phase (default 45 ticks via verticalBoostTicks): Levitation/Invisibility are removed, the blast-off sound plays, a flame+smoke+explosion burst spawns, and verticalBoostVelocity is applied each tick. The true destination coordinates are revealed.
  8. Teleporting phase (single tick): the player is teleported 50 blocks above the destination (clamped to world max height) and Slow Falling is applied.
  9. Dropping phase: the player drifts down with a smoke trail (LARGE_SMOKE + CAMPFIRE_SIGNAL_SMOKE).
  10. Landing phase: Slow Falling is removed early when the player touches the ground (or the max drop duration expires) and an impact burst plays (cloud shockwave, flame ring, dust transition). CannonRTPLandingEvent fires.

Landing Safety Rules

Before a location is accepted into the preload queue, the current code checks, in order:

  • the target world is loaded
  • the search center is valid
  • the candidate is inside the world border
  • the candidate chunk is loaded (loaded on demand without generating)
  • a highest non-air block exists at the candidate column
  • the feet and head spaces above that block are passable
  • the surface block is solid and non-liquid
  • the surface block is not in the configured unsafe ground materials list
  • the feet and head blocks are not in the configured unsafe body materials list
  • all enabled protection plugin integrations allow the location
  • any CannonRTPLocationValidationEvent listener does not veto the candidate

Search attempts are globally rate-limited to one per tick (20/sec), shared fairly across all active cannons via round-robin. Each cannon has its own timeout counter (searchTimeoutAttempts, default 100, minimum 10).

Cannon States

Each cannon has an internal state visible via /wc status or /wc list:

DisplayInternal StateMeaning
Disabled--The cannon is explicitly disabled in its config
ChargingSEARCHING (queue empty)Still preloading its first batch of safe locations
MaintainingSEARCHING (queue not empty)Has some locations but is still refilling consumed slots
ReadyREADYHas enough preloaded locations (>= chargedLocationsPerCannon) to launch players
ExhaustedEXHAUSTEDBurned through searchTimeoutAttempts without filling the reserve
InvalidINVALID_CONFIGURATIONConfiguration error (e.g. target world is not loaded)

A cannon will launch players as soon as it has at least one queued destination. The chargedLocationsPerCannon threshold only affects the visual READY label.

Runtime Expectations

  • Minecraft API: 1.21.4 (tested up to 1.21.11)
  • Java: 21
  • Recommended server software: Paper or a current compatible fork
  • MagmaCore: 2.2.0 or newer (shared library, shaded into the plugin)
  • Optional dependency: FreeMinecraftModels (for 3D animated cannon models)

Resilience

CannonRTP keeps its visuals and queues consistent across world and chunk lifecycle events:

  • when a cannon's chunk unloads, its label and model are despawned; they respawn on chunk reload
  • when a cannon's world unloads, the cannon is suspended; it wakes up if the world is loaded again
  • when FreeMinecraftModels is enabled or disabled mid-session, the model cache is invalidated and visuals refresh on the next tick

Start Here