version 0.5

Citril

A small, readable scripting language — simple to write, and built to be embedded.

Citril has an end-delimited, Lua-flavoured syntax that stays easy to read, a dynamic core you can learn in an afternoon, and a C++ implementation designed to drop into a larger project as its scripting layer.

Download Citril v6 · Windows · free download

What it looks like

function greet(name)
  return "Hello, " + name + "!"
end

let players = ["Ada", "Alan", "Grace"]
for p in players do
  print("${greet(p)} welcome back.")
end

Why Citril

Quick start

Citril builds with CMake and a C++17 compiler.

cmake -S . -B build
cmake --build build --config Release

# run a program (bytecode VM by default)
citril examples/tour.citril

# or the tree-walking interpreter
citril --tree examples/tour.citril

Embedding in a game engine? Citril is designed to be the scripting layer inside a larger C++ program. The Embedding guide walks through linking the library, exposing engine functions to scripts, and calling script functions each frame.