Skip to Content
1robie

Placeholders & tags

How Nexo glyph tags, ItemsAdder images and PlaceholderAPI tags keep working after the move to CraftEngine.

Other plugins' messages, menus and scoreboards were written for Nexo or ItemsAdder. Rather than editing all of them, CraftEngineConverter rewrites the old tags into what CraftEngine draws, wherever text is shown.

Tags it rewrites

TagFromSetting (config.yml)
<glyph:name>Nexo glyphstag.nexo-glyph.enabled
:name:ItemsAdder imagestag.itemsadder-image.enabled
<placeholderapi:placeholder>, <papi:placeholder>PlaceholderAPItag.placeholder-api.enabled

A tag is rewritten to the converted emoji or image, so the glyphs must have been converted first (/cec convert <plugin> EMOJIS and IMAGES). A tag with no converted equivalent is left as it is.

Where they are rewritten

Each place can be turned off in config.yml under formatting:

KeyWhere
packet-eventsOutgoing packets (needs PacketEvents)
boss-barBoss bars
action-barAction bars
plugin-messageMessages sent by plugins
titleTitles and subtitles
menu-titleInventory (menu) titles

PlaceholderAPI

With PlaceholderAPI installed and img-placeholderapi-support on in itemsadder.yml (the default), the plugin registers one placeholder:

PlaceholderReturns
%img_<name>%The converted CraftEngine image for ItemsAdder's <name>

It is the same placeholder ItemsAdder provides, so text using it keeps working once ItemsAdder is gone.

For developers

Other plugins can resolve the same tags through the ITagResolver service:

ITagResolver resolver = getServer().getServicesManager()
    .getRegistration(ITagResolver.class)
    .getProvider();

Last updated on

On this page