Skip to main content

ZTS DocsAlpha

Zero-config · Full C# interop · TypeScript / JavaScript on QuickJS

Mono · 已完成Il2Cpp · 已完成

Unity 2022.3 LTS · QuickJS · Editor Mono + Il2Cpp Player · aligned with ZLua

Easier · zero-config

Declarative GetFunction / [TsMarshalAs], lazy CSharp loading; no per-type Wrap allowlist. Same product mental model as ZLua.

🟦

TypeScript first-class

Official TsProject workflow, csharp: typings, Play-mode gate; runtime still runs emitted ES modules on QuickJS.

📦

Il2Cpp-ready · dual runtime

Editor Mono for iteration; Player Il2Cpp C++ bridge with signature-merged stubs and ByVal / Registry marshaling.

Bidirectional calls at a glance

// Bootstrap
TsAppDomain.Initialize(LoadJsModule);

void Start()
{
    var add = TsAppDomain.GetFunction<Func<int, int, int>>("app", "add");
    Debug.Log(add(10, 20)); // 30
}
// JsScripts/app.js  (canonical: "app")
export function add(a, b) {
  return a + b;
}