promotional bannermobile promotional banner

PlaceholderAPI

Advanced placeholder API for Hytale servers that enables dynamic string substitution with support for player-specific data, caching, parameters, and scoped contexts.
Screenshot 2026-01-17 at 12.39.38.png

Screenshot 2026-01-17 at 12.39.38.png

Description

PlaceholderAPI

A flexible and powerful placeholder system for Hytale server developers. It allows for easy registration and retrieval of dynamic values in strings, with support for caching, player-specific data, parameters, and scoped contexts.

More detailed usage with examples can be found on github.

Features

  • Easy to use: Simple API for both Java and Kotlin developers.
  • Dynamic Values: Support for player-specific placeholders (Visitor-Sensitive).
  • Caching: Built-in support for caching and automatic updates.
  • Parameters: Support for complex placeholders with parameters like %player_name<lc>%.
  • Scopes: Scoped contexts (e.g., Chat, Message) to provide relevant data only where needed.
  • Kotlin First: Type-safe DSL and extension functions for Kotlin developers.

Getting Started

To use the API, you first need to get the PlaceholderAPI instance.

Java:

PlaceholderAPI api = PlaceholderAPI.getInstance();

Kotlin:

val api = PlaceholderAPI.getInstance()

Usage

Translating Strings

To replace all placeholders in a string automatically, use the translateString() method.

Java:

String result = api.translateString("Hello %player_display_name%!", player);

Kotlin:

val result = "Hello %player_display_name%!".translatePlaceholders(player)

Registering Placeholders

Static Placeholders

Example of a placeholder that returns the current server tick:

Kotlin DSL:

api.build<Int>("tick") {
    loader {
        Server.getInstance().tick
    }
}

Visitor-Sensitive Placeholders

Example of a placeholder that returns the player's name:

Kotlin DSL:

api.build<String>("player_name") {
    visitorLoader {
        player.name
    }
}

Advanced Features

Parameters

Placeholders can accept parameters using the %name<param1,param2>% syntax. Example: %player_name<lc>% returns the name in lowercase.

Scopes & Contexts

Scopes allow placeholders to be available only in specific situations (e.g., %message% only available in chat events).


Built-in Placeholders

Placeholder Description Scope
%player_display_name% Player's display name Global
%player_gamemode% Player's game mode Global
%player_x%, %player_y%, %player_z% Player coordinates Global
%server_online% Number of players online Global
%server_ram_used% Server RAM usage Global
%time% Current server time Global
%message% Chat/Message content Chat/Message
%message_sender% Sender of the message Chat/Message

Kotlin Support

PlaceholderAPI offers a Type-safe DSL for registering placeholders and convenient Extension functions for easy integration.

The PlaceholderAPI Team

profile avatar
  • 3
    Followers
  • 6
    Projects
  • 1.3K
    Downloads

More from CreeperFaceView all

  • Bed Wars project image

    Bed Wars

    • 7
    • Mods

    Classic BedWars team PvP for Hytale — protect your bed, raid resource generators, upgrade at the shop, and outlast every other team

    • 7
    • June 13, 2026
    • Mods
    • +1
  • BedWars Configurator project image

    BedWars Configurator

    • 4
    • Mods

    Companion setup tool for the BedWars plugin — build and edit arenas, maps, and shops entirely in-game, no config files required

    • 4
    • June 13, 2026
    • Mods
    • +1
  • UiManager project image

    UiManager

    • 126
    • Mods

    A type-safe Kotlin DSL for building, serializing, and dynamically updating Hytale custom UI with automatic dirty tracking, diff-based updates, event handling, data binding, and form support.

    • 126
    • June 13, 2026
    • Mods
    • +2
  • LuckPerms Placeholders project image

    LuckPerms Placeholders

    • 340
    • Mods

    Provides placeholders from LuckPerms

    • 340
    • June 13, 2026
    • Mods
    • +1
  • Bed Wars project image

    Bed Wars

    • 7
    • Mods

    Classic BedWars team PvP for Hytale — protect your bed, raid resource generators, upgrade at the shop, and outlast every other team

    • 7
    • June 13, 2026
    • Mods
    • +1
  • BedWars Configurator project image

    BedWars Configurator

    • 4
    • Mods

    Companion setup tool for the BedWars plugin — build and edit arenas, maps, and shops entirely in-game, no config files required

    • 4
    • June 13, 2026
    • Mods
    • +1
  • UiManager project image

    UiManager

    • 126
    • Mods

    A type-safe Kotlin DSL for building, serializing, and dynamically updating Hytale custom UI with automatic dirty tracking, diff-based updates, event handling, data binding, and form support.

    • 126
    • June 13, 2026
    • Mods
    • +2
  • LuckPerms Placeholders project image

    LuckPerms Placeholders

    • 340
    • Mods

    Provides placeholders from LuckPerms

    • 340
    • June 13, 2026
    • Mods
    • +1