Text tagging

From OHRRPGCE-Wiki
Jump to: navigation, search
Wip.png
This article discusses a brand new feature which is not included in the latest stable version, and may not even be in the next stable version. It can, however, be found in a nightly build, which can be found on the Downloads page. If you wish to discuss this feature, feel free to use the talk page.

Texttags are special markup for text boxes and other strings of text. They are SOOO new that they aren't even in the nightly builds yet. See this mailing list post for the original proposal

Revise.png
This article or section is not complete. If you wish, you may finish it, and remove this tag when you are done.

Embedding[edit]

  • ${C#} = Hero name at caterpillar slot #
  • ${P#} = Hero name at party slot #
  • ${H#} = Name of hero ID #
  • ${V#} = Global Plotscript Variable ID #
  • ${S#} = Insert String Variable with ID #

In addition, ${V#} will eventually be able to embed any typed global variable, obsoleting ${S#} for strings. Most types would only have printable representations suitable for debugging, though.

Text options[edit]

  • ${F#} - switch to font #
  • ${K#} - set foreground kolour to #. -1 to return to default
  • ${KB#} - set background colour.

If the font is paletted, these changes colours 1 and 2 respectively. If the font is 1-bit (unpaletted) two layer, the background colour is the colour of the shadow/edge.

  • ${KP#} - use palette # (for paletted fonts). -1 to return to default
  • ${KP#} - flicker each printed letter between the colours from palette #, Angband-style! (for unpaletted fonts)

Text slice options[edit]

  • ${W#} - pause for # ticks
  • ${WK} - wait for keypress, while displaying a little down arrow animation that would probably be adjustable somewhere in General Game Settings
  • ${SC#} - slow text: wait # ticks between each non-whitespace letter (0 to resume normal text). Note: maybe we need to support fractional ticks or milliseconds here
  • ${SL#} - slow text: wait # ticks between each line (0 to resume normal text)
  • ${ST#} - set tag # on, for use by scripts waiting for a certain point to be reached - alternatively ${ON#}, ${OFF#}
  • ${SR#} - scroll the text up # lines, hiding the top # lines (more details on modes of scrolling below)
  • ${F#} - play sound effect #

(all text options also available in text slices)

Textbox options[edit]

  • ${PR#} - change the portrait picture to #
  • ${PA#} - play portrait animation #, when that is implemented. Actually I'm not sure about this one, because I wasn't planning on assigning numbers to animations, but always referring to them by name.
  • "${AN"grimace"}" is a bit much.

(all text slice options also available)