Skip to content

Installation

Install OptimalKoth and OptimalLibrary on your Paper or Folia server.

  • OptimalLibrary - required. It is a separate, free plugin that every Optimal plugin runs on (text formatting, storage, holograms, boss bars, regions and more). OptimalKoth will not enable without it.
  • Paper / Folia (or a Paper fork). Spigot is not supported.
  • Minecraft 1.21.11, 26.1.1, 26.1.2, 26.2 or 26.3.
  • Java 21 for 1.21.11, Java 25 for the 26.x versions. Check with java -version.

Optional soft dependency:

  • PlaceholderAPI - registers the %optimalkoth_...% placeholders and resolves %...% placeholders from other plugins inside messages, titles and rewards.

Rewards are commands, so whatever plugin hands out the reward (your economy, crates, keys) needs to be installed as well. The default KOTH template pays out with eco give.

OptimalTeams is optional too: with it installed, the winner’s team earns team points for every capture. Nothing needs to be set up in OptimalKoth for that.

  1. Confirm java -version reports the right version for your server (21 or 25).
  2. Stop the server.
  3. Drop OptimalLibrary.jar and OptimalKoth.jar into plugins/.
  4. (Optional) Add PlaceholderAPI.jar.
  5. Start the server. OptimalKoth generates its files and prints a startup banner with the number of KOTHs, schedules and stored captures.
  6. Run /plugins - OptimalLibrary and OptimalKoth should both be green.

OptimalLibrary downloads its libraries (the SQLite and MySQL drivers, HikariCP and XSeries) on first startup through Paper’s library loader, so the first launch needs internet access and may take a few extra seconds.

plugins/OptimalKoth/
├─ config.yml # storage, timezone, wand, text formats, sounds
├─ messages.yml # every message and title
├─ schedules.yml # when KOTHs start (one disabled example)
├─ koths/ # one file per KOTH, empty until you create one
│ └─ <koth>.yml
└─ data/
└─ data.db # SQLite capture history (do not edit by hand)

No KOTHs ship. The koths/ folder starts empty. Create your first one in-game with the wand, see Creating KOTHs. data/data.db is only created when storage is SQLite.

OptimalKoth stores one row per capture: the KOTH, the winner’s UUID and name, when it was captured and how long the KOTH had been running. This history is what powers {last-winner} and %optimalkoth_wins%.

The backend is set in config.yml under Settings.Storage:

  • SQLite (default) - a local file at data/data.db. Nothing to set up.
  • MySQL - set Type: MYSQL and fill in Host, Port, Database, Username and Password. Use this if several servers should share one capture history.

On startup the win count of every player and the latest capture of every KOTH are loaded into memory. Each capture updates them right away and writes its row in the background. Pending writes are flushed on shutdown.

Continue to Creating KOTHs, or read the Information overview first.