Skip to content

curefate/DialoguePlus

Repository files navigation

DialoguePlus (D+)

logo

DialoguePlus (D+) is a narrative scripting language and runtime framework designed for interactive story experience. It provides a scripting language combined with a compiler + executor architecture, enabling both straightforward authoring and deep runtime customization.

D+ is engine-agnostic at its core, allow host systems to override execution behavior and integrate seamlessly with different game genres.

Navigation

Unity Example

show

This example is from sample scene of Unity Adapter. PS: Yeah I can see it looks... simple, but just for now :3

Features

  • Python-like syntax:
    Clean, easy, zero ambiguity.
  • Customizable:
    Execution behaviour can be overriden by host system, suitable for most game genres.
  • Modular and Extensible:
    Core library is engine-agnostic.

Quick Start

1. Write a Script

Create a .dp file with your story:

Bob "Hello! Welcome to DialoguePlus."
Bob "What's your favorite color?"
"Red":
    Bob "Red is vibrant!"
"Blue":
    Bob "Blue is calming."
Bob "Thanks for trying D+!"

2. Compile and Execute

In Unity:

await DialoguePlusAdapter.Instance.ExecuteToEnd("path/to/script.dp");

In C# (Console):

var compiler = new Compiler();
var result = compiler.Compile("path/to/script.dp");

if (result.Success)
{
    var executer = new Executer();
    executer.Prepare(result.Labels);
    await executer.AutoStepAsync(0); // Run to completion
}

3. Learn More

Repository Structure

  • Core Library: src/

  • Unity Adapter: adapter/Unity

License

MIT License

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors