Target: --target unity | Output: C# MonoBehaviour | Platform: Unity Engine (2021+)
Compiles HoloScript to Unity-compatible C# code with MonoBehaviour scripts, prefab hierarchies, and scene setup.
holoscript compile scene.holo --target unity --output ./Assets/Generated/GeneratedScene.cs— MonoBehaviour with component setupGeneratedScene.prefab— Unity prefab (when enabled)GeneratedScene_Materials/— Material assets
# Generate prefabs
holoscript compile scene.holo --target unity --prefabs
# Target specific Unity version
holoscript compile scene.holo --target unity --unity-version 2023.2composition "Unity Demo" {
object "Player" {
@physics
@collidable
@grabbable
geometry: "capsule"
position: [0, 1, 0]
}
light "Sun" {
type: "directional"
intensity: 2.0
cast_shadows: true
}
}
| Trait | Unity Component |
|---|---|
@physics |
Rigidbody |
@collidable |
Collider |
@grabbable |
XR Grab Interactable |
@networked |
Unity Netcode |
@animation |
Animator |
- Publishing & platform terms — Unity legal / Terms of Service
- Platform Overview
- Unreal Compiler
- Godot Compiler
- Interaction Traits