SugarCube v2.29.0

SugarCube v2.29.0 has been published.

Downloads & documentation for all Twine/Twee compilers:

Changelog highlights:

  • Fixed audio tracks not being initially synchronized with the master audio settings.
  • Fixed line continuations failing in pathological situations.
  • Fixed the <<createplaylist>> macro’s track actions to actually be optional as intended.
  • Fixed many macro debug views in Test mode.
  • Added a simple text replacement markup: templates (?template).
  • Added the <<cycle>> macro, which allows cycling links.
  • Added support for <<capture>> to all interactive macros.
  • Added documentation for the SimpleAudio API.
  • Added Dialog API events: :dialogopening, :dialogopened, :dialogclosing, :dialogclosed.
  • Added the State.metadata API and companion user functions: forget(), memorize(), recall(), which allow access to the persistent story metadata store. Deprecated the <<remember>> and <<forget>> macros in favor of the new user functions.
  • Added the State.prng API, which allows read-only access to parts of the seedable PRNG (if enabled). Deprecated State.initPRNG() in favor of State.prng.init().
  • Added the UIBar.hide(),, UIBar.isHidden(), and UIBar.isStowed() static methods.
  • Added additional ES2017–ES2019 method polyfills: <Array>.flat(), <Array>.flatMap(), Object.entries(), Object.fromEntries(), Object.getOwnPropertyDescriptors(), Object.values(). Deprecated the <Array>.flatten() extension method in favor of <Array>.flat(Infinity).
  • Updated the <<for>> range form to allow the collection expression to be span multiple lines.
  • Updated the <<listbox>> <<option>> tag value argument to be optional.
  • Updated the documentation: fixes, cleanup, and expansion. It’s still primarily reference documentation.
  • Deprecated the <<createplaylist>> <<track>> copy keyword in favor of own.
  • Deprecated UIBar.setStoryElements() in favor of UIBar.update().
  • Removed the <div#store-area> container from the Twine 2 build as it’s served its purpose.
  • Various internal changes: mostly improvements, some extra validation of key story values.
  • Updated bundled libraries:
    • es5-shim to v4.5.13.
    • jQuery to v3.4.1.