@relu-interactives/spatial-ecs
@relu-interactives/spatial-ecs / index / XRHitTestSystem
Class: XRHitTestSystem ​
Defined in: systems/XRHitTestSystem.ts:57
Implements ​
Constructors ​
Constructor ​
ts
new XRHitTestSystem(): XRHitTestSystem;Returns ​
XRHitTestSystem
Properties ​
| Property | Modifier | Type | Default value | Description | Defined in |
|---|---|---|---|---|---|
runsWhilePaused | readonly | true | true | Keep ticking while the world is paused. Leave it unset for anything that moves the game on: such a system stops at world.pause() and picks up where it was at world.resume(). | systems/XRHitTestSystem.ts:58 |
Methods ​
update() ​
ts
update(world): void;Defined in: systems/XRHitTestSystem.ts:66
Parameters ​
| Parameter | Type |
|---|---|
world | World |
Returns ​
void
Implementation of ​
getHitResult() ​
ts
getHitResult(target?): XrHitResult | null;Defined in: systems/XRHitTestSystem.ts:121
Where the given ray meets the real world this frame, or null.
Null is the normal case, not an error: the source may still be being requested, the ray may point at nothing recognised, or the runtime may not have granted hit-test at all.
Parameters ​
| Parameter | Type | Default value |
|---|---|---|
target | TargetKey | "viewer" |
Returns ​
XrHitResult | null
dispose() ​
ts
dispose(): void;Defined in: systems/XRHitTestSystem.ts:188
Returns ​
void

