Transition Script
Context: HL Kit … Kit Reference … Script Types
Technical Details
Initial Context: Hero Alternate Context: None Fields Finalized? Yes
The Transition script utilizes the following special symbols:
message Entry: The empty string to indicate that no transition message should be shown to the user.
Exit: If non-empty, specifies the transition message to be shown to the user as a reminder.
Description
The Transition script is only utilized when the formalized advancement mechanism is enabled for the game system. This script allows the author to display a message to the user whenever the user successfully switches from creation mode to advancement mode, or vice versa. In general, the message is simply a reminder about the implications of the transition, as well as how to switch back. If you want to suppress the message, simply use an empty message string (or omit the script entirely). The message starts out centered, although you can change the behavior.
When invoked, a Transition script starts with the actor as its initial context. You are free to refer to any aspect of the character, although doing so is rarely necessary. The primary detail you'll want to check is whether the character is transitioning to creation mode or advancement mode, which can be determined via the "state" context.
Example
The Transition script below shows the standard behavior you'll want to include in your data files. Depending on the new mode, an appropriate message is displayed.
if (state.iscreate <> 0) then @message = "{b}{text ffff00}Creation Phase{text 010101}{/b}" @message &= "\n\n" @message &= "{align left}You have unlocked your character!" else @message = "{b}{text ffff00}Advancement Phase{text 010101}{/b}" @message &= "\n\n" @message &= "{align left}You have locked your character creation traits. " endif