Ktory LogoKtory
Ktory Logo

Ktory

A Dialogue-First, Host-Driven Narrative Language

A dialogue-first, host-driven narrative language and runtime for independent authors.Dialogue, parameterized decorators and inline translations share a narrative structure; hosts implement resources and presentation.

Screenplay Syntax & Discrete Step

Script Syntax & Discrete Stepping

This simplified simulation illustrates script layout and beat-by-beat choices. It does not run the C# core or validate full semantics. Use the online reader to check real scripts.

sample.en.ktr
Anchor-Decorator
1// Title: Prologue: Departure
2Alice: The wind today seems somewhat unusual.
3 .expression(pensive)
4 .wait(400)
5 
6Leaves swirl outside the window as the bell tower tolls for the third time.
7 
8Alice: Are you ready? We are about to set off.
9 .voice(alice_03_ready)
10 
11#choice.loop
12 * [I'm ready] -> Proceed
13 + [Need a bit more time] => WaitMore
14 
15=== Proceed ===
16 Alice: Then hold my hand tight and stay close, don't let go.
17 .expression(smile)
18 .sfx(dash)
19 -> end
20 
21=== WaitMore ===
22 Alice: All right, three more minutes to pack your gear. We'll wait right here.
23 .expression(neutral)
24 .wait(180)
25 -> return
26 
Sequencer Output BeatSuspendedAtBeat
1 (root)
Speaker:
Attached Decorators (Tags):
Core Pillars

Four Core Architectural Pillars

Anchor-Decorator Model

Dialogue and directives form logical stopping points. Decorators carry presentation cues and arguments, separating narrative structure from resources, animation and display.

Host-Owned Rendering and Time

The core owns narrative flow, choices and session history. The host owns world state, resources, rendering, clocks and raw input, and decides when to request another beat.

Shared C# Core

The core targets netstandard2.1 without external NuGet dependencies. Reader tools use net9.0; the Unity publishing workflow bundles shared sources as com.ktory.unity.

Single-File Inline Localization

Keep translations in one file with @locale. The core selects requested text or a default-language fallback, preserving narrative position and session history when switching languages.