Skip to content

Translations

shmitzas edited this page Nov 12, 2026 · 2 revisions

Translations

Every line CustomHUD shows players comes from resources/translations/<language>.jsonc (in addons/swiftlys2/plugins/CustomHUD/). It ships en, lt and pt-BR; pt-BR covers about half the lines, and a line or file a language lacks falls back to en.jsonc.

  • Restart after editing. Translations load at start.
  • An update replaces these files. Copy your changes back afterwards.
  • A player reads their game language while SwiftlyS2's UsePlayerLanguage is on, its default, and the server's Language otherwise.

CS2 has no Lithuanian client language, so lt.jsonc reaches players only with SwiftlyS2's Language set to lt and UsePlayerLanguage off.


Keys

Keys Shown
customhud.prefix, customhud.nav.*, customhud.scale.* Replies to !setnav and !hudscale
customhud.test.* Replies to !ch_test, and the sample centre message and alert it sends without text of its own
customhud.hint.<mode>, customhud.hint.<mode>.view The footer line per mode — Hints
customhud.legend.<verb> The words in the list's key legend
customhud.eyebrow.<plugin> The line naming a plugin over its menus — Eyebrows
customhud.lead The tag on a vote's leading row
customhud.ranks.*, customhud.weaponstats.*, customhud.prestige.*, customhud.weaponskins.*, customhud.shop.*, customhud.maps.*, customhud.vip.*, customhud.admins.* Captions on the designed pages

Only the chat replies take SwiftlyS2 colour tags such as [green]. Everything else is drawn by the HUD and must be plain text, and the page captions must not contain ;.


Eyebrows

The line naming a menu's plugin: the band over the title in the _v2 layouts, gold over it in the first designs. In a submenu it is the top menu's title; on a top menu, CustomHUD shows the first of these that exists:

  1. customhud.eyebrow.<plugin>, where <plugin> is the first part of the menu's id: missions for missions.main.
  2. The supported plugins' own lines: customhud.eyebrow.shop, maps, ranks, vip, admins and mix.
  3. customhud.eyebrow.default.

"" shows no line, and colour tags are dropped. A key added to en.jsonc alone reaches every language. DetailedLogging logs each menu's id: [CustomHUD] applied slot=3 menu=missions.main ….

Example

Your server's name over every other plugin's top menus, Missions over menus whose ids start with missions., and no line over arenas. menus:

{
  "customhud.eyebrow.default": "My Server",
  "customhud.eyebrow.missions": "Missions",
  "customhud.eyebrow.arenas": ""
}

Add the lines to en.jsonc, then restart.

Clone this wiki locally