Crate kataru

Source

Macros§

error

Structs§

AttributedSpan
A span of text with a map of attributes and values.
Bookmark
All data necessary to find your place in the story.
CharacterData
Choices
Public interface to choices, just gives choice names.
Command
Public interface for a command.
Config
Dialogue
Input
Position
Return
Runner
The self-referencing struct.
Section
SetCommand
StateMod
Story
Represents the story, which is a map of namespaces to their sections.
Validator

Enums§

AssignOperator
Entry
A view into a single entry in a map, which may either be vacant or occupied.
Error
Error type for validating the kataru yml script.
Line
Public interface for a line in a Kataru script.
LineTag
Operator
Value

Statics§

GLOBAL

Traits§

FromMessagePack
Trait for extract config/story from MessagePack bytes.
FromYaml
Trait for parsable expressions.
Load
LoadMessagePack
Trait to load a struct from a file or structured directory.
LoadYaml
Trait to load a struct from a file or structured directory.
Merge
Trait to merge two objects together. Used for maps.
Save
SaveMessagePack
Trait to save a serializable object to a MessagePack file.
SaveYaml
Trait to save a serializable object to a YAML file.

Functions§

contains_var
extract_var
Returns Some(&str) when a variable was successfully extracted. Otherwise returns None.
pack
Parses the config and story files into RMP and writes to the output.

Type Aliases§

Map
Params
Passage
Passages
PositionalCommand
PositionalParams
Result
State
Typedef for state, which is a mapping of values.