Compiler Targets
HoloScript compiles a single .holo source file to multiple platform targets.
Canonical target keys are defined in ExportTarget (packages/core/src/compiler/CircuitBreaker.ts).
bash
# SSOT: inspect registered target enum members
grep -n "export enum ExportTarget" -A 200 packages/core/src/compiler/CircuitBreaker.tsCommon targets (non-exhaustive)
| Target Flag | File | Output | Platform |
|---|---|---|---|
--target unity | unity.md | C# MonoBehaviour | Unity Engine |
--target unreal | unreal.md | C++ / Blueprint | Unreal Engine 5 |
--target godot | godot.md | GDScript | Godot Engine 4.x |
--target vrchat | vrchat.md | UdonSharp C# | VRChat SDK3 |
--target babylon | babylon.md | JavaScript | Babylon.js |
--target webgpu | webgpu.md | TypeScript | Modern Browsers |
--target ios | ios.md | Swift + ARKit | iOS 15+ |
--target visionos | vision-os.md | Swift + RealityKit | Apple Vision Pro |
--target android | android.md | Kotlin + ARCore | Android SDK 26+ |
--target androidxr | android-xr.md | Kotlin | Android XR |
--target openxr | openxr.md | C++ | Cross-platform XR |
--target threejs | three-js.md | JavaScript | Three.js / Web |
--target gltf | gltf.md | GLB/glTF | Universal 3D |
--target wasm | wasm.md | WASM binary | WebAssembly |
--target urdf | robotics/urdf.md | URDF XML | ROS 2 |
--target sdf | robotics/sdf.md | SDF XML | Gazebo |
--target dtdl | iot/dtdl.md | DTDL JSON | Azure Digital Twins |
--target wot | iot/wot.md | WoT TD JSON | W3C Web of Things |
--target playcanvas | playcanvas.md | JavaScript | PlayCanvas Engine |
--target ar | ar.md | TypeScript | Browser WebXR AR |
--target tsl | tsl.md | WGSL | Trait Shader Language |
--target neuromorphic | neuromorphic.md | NIR bytecode | Loihi2 / SpiNNaker |
--target a2a | a2a.md | JSON Agent Card | Google A2A Protocol |
--target scm | scm.md | Python + dowhy | Causal AI |
--target usd-physics | usd-physics.md | USD Physics JSON | visionOS / Omniverse |
--target openxr-spatial | openxr-spatial.md | OpenXR JSON | AR/VR Anchoring |
--target ai-glasses | ai-glasses.md | Platform SDK | Meta / Snap / Apple Glasses |
--target vr-reality | vr-reality.md | Phoenix WebXR | VRR Digital Twins |
--target nft-marketplace | nft-marketplace.md | Solidity + JS | NFT / Web3 |
Common Compiler Options
All compilers support:
| Option | Description |
|---|---|
--output <path> | Output directory |
--verbose | Show detailed compilation info |
--watch | Recompile on file changes |
--sourcemap | Generate source maps (where applicable) |
Usage
bash
# Compile to a specific target
holoscript compile scene.holo --target unity --output ./Assets/Generated/
# Compile to multiple targets
holoscript compile scene.holo --target unity --target godot --output ./builds/
# Watch mode
holoscript compile scene.holo --target webgpu --watchGroupings
Game Engines
Unity · Unreal · Godot · VRChat
Web & Browser
WebGPU · Three.js · Babylon.js · GLTF · WASM
Mobile & XR
iOS ARKit · visionOS · Android ARCore · Android XR · OpenXR
Robotics
IoT & Digital Twins
Utility Surface (beyond rendering)
Not every utility capability is a compiler target. HoloScript also provides:
| Capability | Where to look |
|---|---|
| Data/service pipelines | .hs flows and Node/service-oriented targets (for runtime orchestration) |
| Agent interoperability | A2A target and protocol docs in docs/agents/ |
| Schema mapping / digital twins | DTDL, WoT, Absorb docs |
| Observability and tracing | Telemetry/tracing paths in core/runtime + platform docs |
| Knowledge market and team ops | HoloMesh and orchestrator APIs (not compiler outputs) |
Use compiler docs for output artifacts, and use runtime/service docs for orchestration, observability, and marketplace flows.
See Also
- Traits Reference — Trait → platform mapping
- CLI Reference — Full compiler CLI options
- Python Bindings — Compile from Python