Function: CameraForLayer()
ts
function CameraForLayer(scene, layer): Entity | null;Pointer ↔ UI-local conversions for the UI controls (Slider, InputField). They go through the camera that actually draws the entity — the topmost enabled screen camera whose culling mask holds its layer — not the main camera, which may be a world camera under a UI one.
Parameters
| Parameter | Type |
|---|---|
scene | Scene |
layer | number |
Returns
Entity | null