Assets/_MolcaSDK/_VR/) on Molca Core. For cross-product Core placement, see Architecture. For content structure (modules → scenario → simulation vs tour), see VR content hierarchy.
Layers (VR training on Molca Core)
Dependency direction: your VR training content calls into the VR SDK; the VR SDK sits on Molca Core; both run on Unity + XR.Glossary (VR training)
Scenario state (ScenarioManager)
ScenarioState: Inactive, Active, Paused, Completed, Terminated, TimedOut.
FailScenario() sets Terminated. API comments note that success and failure can both end as a finished session from the backend’s perspective; pass/fail may depend on posted scores. Inspect CompleteScenario, FailScenario, and TimeoutScenario in Scenario/ScenarioManager.cs when customizing outcomes.
Typical VR app flow (molca-sdk-vr)
- Preload —
VRPreloadCheckruns child components implementingIPreloadCheck(_MolcaSDK/Code/.../Preload/). - Auth —
ScenarioSessionManager.VisitorLoginAsync(6-digit OTP) orMemberLoginAsync(email, password). Avoid obsoleteMemberLoginAsyncUsingClerk. - Home —
HomeUIManager+ScenarioDataConfig(and fetched org content when connected). - Scenario —
ScenarioManager+ mode driver; simulation uses activities/sequences; tour usesTourSubsystem. - End — completion / timeout / fail UI + session status and scores via
ScenarioNetworkConfig.
Scenario lifecycle states
ScenarioState on ScenarioManager (simplified — see source for guards):
Pause UI: PauseScenario() / ResumeScenario() only show or hide the pause modal. CurrentState stays Active; sequences and timers keep running (see API comments in ScenarioManager.cs). The enum includes Paused, but that path is not used by the pause modal flow.
Connected session (high level)
VR entry-point cheat sheet
Related
- VR overview — doc hub for this SDK
- VR content hierarchy — simulation vs tour trees
- VR assets and scenes — ScriptableObjects vs Unity scenes
- Runtime and settings — shared bootstrap