InkGameScript Documentation
Welcome to the official documentation for InkGameScript – the open-source narrative scripting language for interactive fiction and games. Here you will find everything you need to get started with InkGameScript, from quick start guides and tutorials to API references and best practices. Whether you are a beginner or an experienced developer, this documentation will help you unlock the full potential of InkGameScript and inkjs for your next interactive story or game.
Quick Start Guide
Getting started with InkGameScript is easy. Download the Inky editor, write your first story, and export it for use with inkjs. InkGameScript enables you to create deeply branching narratives with simple markup and powerful logic.
Hello World Example
=== start ===
Hello, world! This is your first InkGameScript story.
* [Continue] -> next
=== next ===
Congratulations! You've created your first branching narrative.
This example demonstrates the basic Ink syntax and story flow. You can add choices, variables, and conditions to make your story interactive and dynamic.

Core Concepts
Branching & Choices
Create choices, knots, diverts, and manage story flow with InkGameScript. Example:
* [Go left] -> left_path
* [Go right] -> right_path
Variables & Conditions
Use variables and conditions to add logic to your stories. Example:
VAR health = 10
{ health > 5: You feel strong. }

API Reference
inkjs API Overview
Load and run InkGameScript stories in the browser with inkjs:
var story = new inkjs.Story(storyContent);
var text = story.Continue();
var choices = story.currentChoices;
Integration Tips
- Use inkjs with HTML/JavaScript for seamless web integration
- Customize the user interface with CSS
- Handle user input and manage story state for interactive experiences

Tutorials & Best Practices
Writing Tips
- Keep your narrative structure clear and modular
- Use knots and diverts for better organization
- Test your story frequently in Inky
Advanced Features
- Functions, lists, and external functions
- Saving and loading story state
- Localization and accessibility support
FAQ & Resources
Frequently Asked Questions
- How do I debug my Ink story?
- Can I use InkGameScript for commercial projects?
- Where can I find more examples?
More Resources
