WarmLoop Logo

Healing Library

WarmLoop Logo

WarmScript

Features

Dynamic content system for personalized narratives


WarmScript is WarmLoop's dynamic content system that creates personalized, adaptive narratives. It combines variables, conditional blocks, and settings to tailor every interaction to your specific context.

Overview

WarmScript enables scenarios to:

  • Adapt to different character combinations
  • Personalize content with names and pronouns
  • Show/hide content based on context
  • Generate dynamic dialog
  • Respond to user preferences

Variables

Basic Character Variables

Replace role placeholders with assigned character names:

{mentor} looks at you thoughtfully.
{friend_1} and {friend_2} exchange glances.
Numbered Roles: Use _1, _2 for multiple characters in the same role: {parent_1} - First parent character {parent_2} - Second parent character

Enhanced Variables

Add type modifiers for pronouns and variations:

Pronouns

{teacher:she} raises {teacher:her} hand.
{guardian:they} examine {guardian:their} map.
Available pronouns: :subject (she/he/they) :object (her/him/them) :possessive (her/his/their) :reflexive (herself/himself/themself)

Name Variations

{character:first} - First name only {character:role} - Role title (e.g., "mom" for mother)

Special Variables

{user} - The persona/player name {user:possessive} - User's possessive pronoun

Dynamic Dialog

Generate contextual character dialog in the starting message, creating unique scenario openings based on who's present:

{mentor:dialog:"offer encouragement"}
// Generates: "You're doing well," Alex says with a warm smile.

{mentor:dialog:"praise their progress"}
// Generates guided dialog following the instruction

{mentor:long_dialog:"explain the situation and offer comfort"}
// Generates extended narrative with multiple dialog lines

{colleague:dialog}
// Without guidance, AI generates contextually appropriate dialog
// (Best practice: always provide guidance for predictable results)

Note: Dialog generation happens when the scenario starts, personalizing the opening message based on the actual characters selected. This ensures each playthrough begins with dialog that matches the specific character's personality and voice.

Conditional Blocks

Basic Syntax

Show content only when conditions are met:

[requires: teacher]
  {teacher} begins today's lesson.
[else]
  You study alone in the quiet library.
[/requires]

Multiple Conditions

Chain conditions with [else requires:] for fallback options:
[requires: mentor]
  {mentor} offers guidance.
[else requires: friend]
  {friend} gives their best advice.
[else]
  You rely on your own judgment.
[/requires]

Character Name Conditions

Target specific characters by name:

[requires: "Luna the Wise"]
  Luna's ancient wisdom illuminates the path.
[else requires: teacher]
  {teacher} shares what knowledge {teacher:they} can.
[/requires]

Nested Conditions

Conditions can contain other conditions:

[requires: guardian]
  {guardian} approaches.
  [requires: "Protective Sam"]
    Sam's protective instincts kick in immediately.
  [else]
    {guardian:they} assess the situation carefully.
  [/requires]
[/requires]

Settings Integration

Direct Variable Usage

Use custom settings as variables anywhere:

Welcome to {city_name}!
The {weather} sky stretches above.
Your {companion_title} awaits at the {meeting_place}.

Setting Conditions

Show content based on setting values:

[requires setting:difficulty="easy"]
  Helpful markers guide your way.
[else setting:difficulty="challenging"]
  You'll need to find your own path.
[/requires]

[requires setting:relationship="close"]
  {friend} greets you with a warm hug.
[else setting:relationship="formal"]
  {friend} offers a polite nod.
[/requires]

Combining Systems

Settings work seamlessly with character variables. Custom settings (like user_nickname below) must be defined in the scenario's custom settings configuration:
{guardian} leads you through {city_name}.

[requires setting:pace="relaxed"]
  "No rush, {user_nickname}," {guardian:they} say gently.
[else setting:pace="urgent"]
  "Quick, {user_nickname}!" {guardian} urges.
[/requires]

In this example:

  • {city_name} and {user_nickname} are custom settings variables
  • {guardian} and {guardian:they} are character variables
  • Users would set these values when starting the scenario

Practical Examples

Adaptive Greeting

[requires: "Caring Maya"]
  Maya wraps you in her signature warm embrace.
[else requires: mentor]
  {mentor} greets you with {mentor:possessive} usual {formality} manner.
[else]
  You enter quietly, unnoticed.
[/requires]

With settings:

formality: "warm" → "their usual warm manner"
formality: "professional" → "their usual professional manner"

Dynamic Scene

The {time_of_day} sun illuminates {location}.

[requires: companion]
  {companion} walks beside you, {companion:dialog:"comment on the beauty of the scene"}
  
  [requires setting:bond="deep"]
    {companion:possessive} hand finds yours.
  [/requires]
[else]
  You take in the view alone, peaceful in solitude.
[/requires]

Complex Interaction

[requires: "Wise Elder Chen"]
  Elder Chen strokes his beard thoughtfully.
  "The answer you seek lies within, young one."
[else requires: teacher]
  {teacher:dialog:"provide mysterious guidance that hints at inner wisdom"}
[else]
  The ancient texts remain silent.
[/requires]

[requires setting:understanding="high"]
  The meaning becomes crystal clear.
[else]
  You ponder what this could mean.
[/requires]

Cascading Conditions

[requires: protector]
  {protector} stands guard.
  [requires: "Fierce Anya"]
    Anya's hand rests on her sword hilt, ready.
  [else requires setting:danger="high"]
    {protector:possessive} stance shifts to high alert.
  [else]
    {protector:they} maintain a watchful but relaxed presence.
  [/requires]
[else requires setting:danger="high"]
  You feel exposed without protection.
[else]
  The area feels safe enough.
[/requires]

Best Practices

Content Design

  1. Always provide fallbacks - Include [else] blocks for essential content
  2. Use roles for flexibility - {teacher} works with any teacher character
  3. Use names for specificity - "Professor Oak" for character-specific content
  4. Layer your conditions - Combine character and setting conditions for richness

Performance Tips

Variables process faster than conditional blocks. Shallow nesting performs better than deep nesting. Character name conditions should be used sparingly.

Writing Guidelines

Keep dialog guidance concise but clear. Use long_dialog for emotional moments. Test with various character combinations. Always consider the "no character assigned" case.

Common Patterns

Optional Character Enhancement

You approach the door.
[requires: companion]
  {companion} is right behind you.
[/requires]

Progressive Difficulty

[requires setting:experience="beginner"]
  Clear instructions appear: {detailed_guide}
[else setting:experience="intermediate"]
  A brief note hints: {subtle_hint}
[else]
  No guidance is provided.
[/requires]

Relationship Dynamics

[requires: friend]
  [requires setting:trust="high"]
    {friend:dialog:"share a personal secret that shows deep trust"}
  [else]
    {friend:dialog:"make casual friendly conversation"}
  [/requires]
[/requires]

Limitations

No computed conditions - Can't use score > 10 or similar No variable math - Can't combine or calculate values Settings must be predefined - Can't create settings on the fly Character names must match exactly - After normalization (removes parentheses)

Advanced Usage

Mixed Variable Types

{mentor} says to {user}, "{user:first}, 
{mentor:possessive} faith in you is absolute."

Conditional Dialog Generation

[requires: advisor]
  {advisor:dialog:"warn about [requires setting:threat='magical']magical dangers[else]local bandits[/requires]"}
[/requires]

Setting-Aware Pronouns

{guardian} extends {guardian:possessive} hand.
"Trust {guardian:object}," {companion} urges.

WarmScript transforms static content into living, responsive narratives that adapt to each user's unique journey. By combining these systems thoughtfully, you create experiences that feel personally crafted for every interaction.


On this page

Home

Search