Expand description
Miscellaneous convenience functions.
Enums§
- Action
OrEvent 🔒 - Allow
Inject - Basically a named bool.
- Choices 🔒
- The Choices enum exists to hook into the Display logic of printing to a string
- Prefix
Should - TriBool
Constants§
- BANNED_
NAMES - Warn if a scripted item has one of these names, and ignore it when validating.
This avoids tons of errors from for example a scripted effect named
if. Such an effect can happen accidentally with a misplaced brace or two.
Traits§
- Tiger
Hash MapExt - A convenience trait that can be used together with the type aliases defined to
get access to the
new()andwith_capacity()methods for the HashMap type alias. - Tiger
Hash SetExt - A convenience trait that can be used together with the type aliases defined to
get access to the
new()andwith_capacity()methods for the HashSet type aliases.
Functions§
- camel_
case_ to_ separated_ words - display_
choices - dup_
assign_ error - Warns about a duplicate
key = valuein a database item.keyis the new one,otheris the old one. - dup_
error - Warns about a redefinition of a database item
- exact_
dup_ advice - Warns about a redefinition of a database item, but only at “advice” level
- exact_
dup_ error - Warns about an exact redefinition of a database item
- is_
country_ tag - item_
prefix_ should - Used for prefixed items other than effects, triggers, and modifiers.
- limited_
item_ prefix_ should_ insert - Used for scripted triggers, effects, and modifiers. Handles the
REPLACE:etc prefixes, and returns the name to insert under iff the new item should be inserted. - snake_
case_ to_ camel_ case - stringify_
choices - stringify_
list