Skip to content

Configuration

EmakiCodex configuration is split into main settings, advancement pages, and language files. This page covers config.yml and lang/*.yml:

  • config.yml: global switches, default resource release, advancement registration, and PacketEvents coordinate channel.
  • lang/*.yml: command and console messages.

The page and node fields of advancements/*.yml are documented in Advancements, and automatic grants in Triggers.

config.yml

Default main configuration:

yaml
version: "1.0.0"
language: "zh_CN"
release_default_data: true
op_bypass: false

advancement:
  enabled: true
  platform: unsafe
  announce-default: false
  remove-on-disable: true
  packet-coordinates: true
  triggers-enabled: true

debug: false

Field reference:

FieldTypeDefaultDescription
versionstring1.0.0Default resource version marker.
languagestringzh_CNUses lang/<language>.yml.
release_default_databooleantrueReleases bundled advancements/example_page.yml when missing.
op_bypassbooleanfalseKey kept in the default config. The current implementation reads the value but has no permission branch that uses it; OPs still gain admin access through the permission defaults in paper-plugin.yml.
advancement.enabledbooleantrueEnables vanilla advancement registration.
advancement.platformstringunsafeDynamic registration platform. The current implementation uses Bukkit unsafe advancement registration; a blank value falls back to unsafe.
advancement.announce-defaultbooleanfalseDefault broadcast behavior when a node does not define announce.
advancement.remove-on-disablebooleantrueRemoves registered dynamic advancements when the plugin is disabled. The /codex reload rebuild always clears the plugin namespace before registering, regardless of this switch.
advancement.packet-coordinatesbooleantrueInjects node x / y into the client tree when PacketEvents is installed. This switch only decides whether the PacketEvents listener is registered at enable time; changing it at runtime requires a restart.
advancement.triggers-enabledbooleantrueEnables automatic triggers.entries grants. When disabled, nodes can only be granted by commands, API, or CoreLib actions.
debugbooleanfalseKey kept in the default config. The current implementation does not read it; debug output is managed through /codex debug.

Language files

Language files live in lang/*.yml. The default includes:

yaml
version: "1.0.0"
general:
  prefix: "<gray>[ <gradient:#F59E0B:#EC4899>EmakiCodex</gradient> ]</gray>"
  no_permission: "<red>You do not have permission to do that.</red>"

command:
  help:
    commands:
      reload: "Reload config, re-register advancements, resync all"
      grant: "Grant an advancement to a player"
      revoke: "Revoke an advancement from a player"
      debug: "Manage debug mode"

Language text supports MiniMessage. Run /codex reload after editing.

After editing config.yml, advancements/*.yml, or lang/*.yml, run /codex reload to apply the changes.

  • Advancements: the page and node fields of advancements/*.yml, the key rules and completion actions.
  • Triggers: how to write triggers.entries, the available events and condition examples.
  • Commands and Permissions: /codex reload, granting and revoking.
  • CoreLib Actions: granting or revoking advancements from an action chain.