Elias Unity Plugin
Technical documentation
Elias Unity Plugin User Guide
This guide focuses on using the Elias Unity Plugin in everyday production workflows. It intentionally avoids deeper implementation details, which are covered in the technical documentation.
Package Installation
You can find the Elias Unity Plugin in the Extras folder of Elias Studio.
- Open Elias Studio and go to About > Extras.
- Locate audio.elias.unity-plugin.tgz.
- In Unity, open Window > Package Manager.
- Click + and choose Add package from tarball..., then select the file.
- Optional: install the plugin samples from the package entry.
Version Compatibility (Important)
Use the same Elias version across your team. Elias Studio and the Unity Plugin should come from the same installer.
- Check Elias Studio version in the About dialog.
- Check plugin version in Window > Elias > About in Unity.
Supported Platforms
- Windows (x64)
- macOS (arm64, x64)
- iOS (arm64, simulator arm64/x64)
- Android (arm64, armv7, x64)
Quick Start
- Create an Elias Asset Context asset in your project (usually under Assets/).
- In the Asset Context inspector, browse to your .elias project file and click Refresh.
- Add an Elias Session component in your scene.
- Click Initialize on the session so settings match the Elias project.
- Add an Elias Listener (usually on the main camera).
- Add one or more Elias Sound Instance components and select Patch/Config assets.
Elias Project and Asset Contexts
Elias content is connected through Elias Asset Context assets.
- Context lookup is folder-based: Unity assets/scenes use the closest context in the folder hierarchy.
- Child folders can inherit from parent contexts.
- You can use multiple contexts for large projects, DLC, or separated content roots.
Addressables and Context Placement
- For main game content, keep your root Asset Context non-addressable so Elias runtime models are exported to StreamingAssets.
- For DLC/addressable content, place a dedicated Asset Context in that DLC folder and mark it/addressable content accordingly.
Why Components Can Become Invalid
If you switch the Elias project in a context, related Elias components may become invalid until reselected/reinitialized. This is expected and prevents project/schema mismatches.
Components Overview
Elias Session
- Required for playback. No active session means no Elias audio.
- Stores runtime audio settings (sample rate, channel count, buffer size, instance limit).
- Use Initialize to copy settings from the selected Elias project.
- If you use multiple sessions, explicitly assign session references on listener/sound/zone components.
Elias Listener
- Represents the listener position/orientation used for spatialization.
- Typically placed on the main camera.
- If no session is explicitly assigned, it will use a session found in the scene.
Elias Sound Instance
- Select a Patch or Config in the inspector.
- Use parameter updates from code to drive behavior at runtime.
- Inspector supports live parameter controls in play mode.
- Use Refresh if parameter lists are out of date after Elias project edits.
Elias Zone Instance
- Select a Zone asset in the inspector.
- Enable Edit vertices to edit zone geometry in Scene view.
- Drag handles to move vertices.
- Hold Ctrl/Cmd to add vertices on edges.
Parameters
Elias parameters are controlled in two scopes:
- Global parameters: set on EliasSession.
- Patch/Config parameters: set on EliasSoundInstance.
Supported types: pulse, boolean, int, float, enum.
C# Scripting Example
using UnityEngine;
using Elias.UnityPlugin;
public class AudioController : MonoBehaviour
{
[SerializeField] private EliasSession session;
[SerializeField] private EliasSoundInstance footsteps;
public void OnJump()
{
footsteps.SendPulse("jump");
}
public void OnEnterWater(bool swimming)
{
footsteps.SetParameterValue("swimming", swimming);
}
public void OnSpeedChanged(float speed)
{
footsteps.SetParameterValue("speed", (double)speed);
}
public void OnSurfaceChanged(string materialName)
{
footsteps.SetParameterValue("FootstepMaterial", materialName);
}
public void SetMusicIntensity(float value)
{
session.SetParameterValue("MusicIntensity", (double)value);
}
}Use exact parameter and enum value names from Elias Studio.
Connected Workflow with Elias Studio
- Keep Elias Studio open while working in Unity.
- Open the project connected to your Unity context.
- In play mode, content edits in Elias Studio can be heard immediately.
Build and Addressables
During player build, Elias exports runtime models automatically.
- Main content is exported to StreamingAssets together with an Elias runtime index.
- Referenced Elias assets are collected from build scenes and relevant prefabs/resources.
- Dependencies are included automatically by Elias export.
Addressables Build Requirement
If Elias content is part of Addressables (for example DLC), use the Elias addressables builder.
- Create an EliasBuilderPackedMode asset under your Addressables DataBuilders folder.
- Select it as the active builder for your addressables build.
If you skip this, Elias runtime models for addressable content are not packaged correctly.
Troubleshooting
- No audio in play mode: confirm an active Elias Session and Elias Listener exist in the scene.
- Component marked invalid: verify Asset Context project path and reselect affected Patch/Zone assets.
- Audio missing in build but works in editor: verify build scenes/addressables include the content, and use EliasBuilderPackedMode for addressables.
- Unexpected project mismatch errors: ensure team uses one Elias Studio/plugin version.
- Changed Elias project settings: re-initialize Session settings from project.
Samples
The EliasFootstepDemo sample demonstrates:
- Asset Context setup
- Session + Listener + Sound Instance usage
- Parameter-driven surface switching
- Optional addressable/DLC content flow
Recommended practice for production: keep your Elias project outside Unity Assets/ even if samples place it inside for convenience.