LUIDA Docs
ComponentsUnity templateEditor windows

LUIDA › Scene menu

Two commands: create a new experiment scene from the LUIDA template, or duplicate the currently-open scene to start a variant.

These pages are not yet fully reviewed. The LUIDA team is continuing to review and improve them. If you find anything wrong on these pages, or have questions that aren't resolved by reading them, please ask or report to the LUIDA team.

LUIDA › Scene is a small two-command sub-menu in the Unity top bar. It's how you add new experiment scenes (or variants of an existing one) to the project. Doing this through the menu rather than copy-pasting .unity files manually matters: the commands also set up the per-scene generated assets (StateList, ExperimentVariables) and ensure the new scene lives in the correct folder for the LUIDA runtime to find it.

The two commands

LUIDA › Scene › Create new scene

Opens a small dialog asking for a new scene name. After you confirm:

  1. Unity creates Assets/_Experiment_/Scenes/<YourName>.unity from the LUIDA template scene.
  2. The scene is opened in the editor.
  3. The matching Settings/StateList/<YourName>.asset and Settings/ExperimentVariables/<YourName>.js files are not created yet — you'll be prompted to "activate the automation feature" the first time you open the Configure experiment automation window on this scene.

Use this when you want a clean experiment from scratch. The template scene includes the runtime prefabs (LUIDA-ExpManagers) pre-placed at the world origin, so the new scene is immediately functional even before you customize anything.

Screenshot pending — the LUIDA › Scene › Create new scene dialog with "Stroop_v2" typed in.

LUIDA › Scene › Duplicate current scene

Asks for a new scene name, then:

  1. Saves the currently-open scene (prompts if there are unsaved changes).
  2. Creates Assets/_Experiment_/Scenes/<YourName>.unity as an exact copy of the active scene.
  3. Also duplicates the matching Settings/StateList/<SourceSceneName>.asset and Settings/ExperimentVariables/<SourceSceneName>.js into the new scene's names, so the new scene immediately has the same automation configuration as the source.

Use this when you want to fork an existing experiment to make a variant — e.g., a pilot version, a different condition setup, or a follow-up study sharing most of the same setup. Forking via Duplicate current scene keeps everything wired up; copying .unity files manually loses the per-scene asset bindings.

Duplicate current scene only works if the active scene lives under Assets/_Experiment_/Scenes/. Scenes outside that folder show a "not a valid experiment scene" error — the LUIDA runtime expects scenes in that path and won't load them from elsewhere.

What a "valid experiment scene" needs

The Scene menu commands generate the right folder layout for you, but if you're inheriting a scene from somewhere else (e.g., a colleague's project), here's what makes it valid:

  • Located at Assets/_Experiment_/Scenes/<Name>.unity.
  • Contains the LUIDA-ExpManagers prefab (or equivalent root that hosts the state machine, condition manager, and participant manager).
  • Contains the LUIDA-DataCollector prefab if the scene logs custom data (insert via GameObject › LUIDA › Data Collector).
  • Has a Settings/StateList/<Name>.asset and Settings/ExperimentVariables/<Name>.js referenced by the prefab.

Opening such a scene and choosing LUIDA › Configure experiment automation lets you edit it through the LUIDA tabs.

Common pitfalls

  • Renaming a .unity file in the Project panel without renaming the matching StateList / ExperimentVariables files. The references go stale. Always use Duplicate current scene for renames, then delete the old scene.
  • Putting scenes outside Assets/_Experiment_/Scenes/. They open in Unity but the LUIDA editor windows refuse them. Move into the right folder.
  • Two scenes sharing the same StateList asset. Possible but error-prone — edits to the state machine in one scene affect the other. Stick to one StateList per scene unless you have a specific reason to share.

Where to go next