L2J

Show live server data on the website

Optional online count, rankings, clans, sieges, and bosses for L2J

These optional providers let Forgeport show live game information in Admin and on the published website. If a provider is missing, its section is unavailable; commerce and delivery continue to work.

Show the online count

Use the live world when the pack exposes it:

ForgeportIntegration.java
.onlineCount(() -> World.getInstance().getPlayers().size())

The count travels with connector heartbeats and powers Admin analytics and the public website.

Show rankings

.rankings((metric, limit) -> ...) receives PVP, PK, or LEVEL. Query the pack database with a parameterized limit and map rows to GameCharacter. Exclude staff characters according to the pack's own access-level policy.

Show clans, sieges, and bosses

  • .clans(limit -> ...) returns GameClan rows.
  • .sieges(() -> ...) returns GameSiege rows with explicit UTC instants.
  • .bosses(() -> ...) returns GameBoss rows and their live state.

The connector validates and serializes these domain objects. Your integration decides which game table or live-world API is authoritative.

After this works

Publish the corresponding Website sections in Admin. The public site and the read-only website API should show current data. An empty list means the query succeeded and found no rows; unavailable data appears as unavailable, not as an invented fallback.

Verify

  1. Run Connector check for each registered provider.
  2. Compare the online count with the live world.
  3. Compare one ranking, clan, siege, and boss row with the game/database.
  4. Publish the Website draft and inspect the visible section.

On this page