Input System
Oasis routes world input through a single state machine.
Input states
Current states in src/lib/input-manager.ts:
orbitnoclipthird-personagent-focusplacementpaintui-focused
Why this matters
The input manager is the current source of truth for:
- movement permissions
- mouse look permissions
- pointer lock lifecycle
- transform shortcut availability
- whether object selection should work
That means other parts of the app should ask the input manager what is allowed instead of re-deriving input behavior ad hoc.
Important files
| File | Responsibility |
|---|---|
src/lib/input-manager.ts | State machine, capabilities, pointer lock lifecycle |
src/components/CameraController.tsx | Camera behavior for world movement |
src/components/forge/WorldObjects.tsx | Selection and transform shortcuts |
src/components/forge/WizardConsole.tsx | UI-side interactions |
src/components/forge/AgentWindow3D.tsx | In-world window interaction |
src/components/forge/AgentWindowPortals.tsx | DOM portal bridge for agent surfaces |
Current transform shortcuts
Selected-object transform mode is switched with:
Rfor translateTfor rotateYfor scale
Do not document the older W / E / R mapping for this codebase.
Current movement shortcuts
The Help panel and input manager currently reflect:
WASDmoveQ / Evertical movement in noclipShiftsprintSpaceslow movementCtrl + Alt + Ccycle camera mode
Documentation rule
When you update input docs, use src/lib/input-manager.ts and the in-app Help panel as the source of truth.