import * as THREE from 'three'; /** Minimal body shape required by raycast helpers. */ export interface RaycastBody { group: THREE.Group; config: { radius: number; }; } /** Optional tuning for {@link raycastBodies}. */ export interface RaycastBodiesOptions { /** Index of the focused body — skipped as a candidate and used as occluder. */ focusedIndex?: number | null; } /** * Result returned by {@link raycastBodies} — the index of the first body * hit and the raw THREE intersection for callers that need the exact point * or object. */ export interface RaycastHit { bodyIndex: number; intersection: THREE.Intersection; } /** * Makes every object under `root` transparent to scene raycasting by * replacing its `raycast` method with a no-op. Used for display-only bodies * whose picking is delegated to a caller-owned hitbox — the body's own meshes * (atmo shell, smooth sphere) must not intercept the ray and swallow the * click. One-way by design: a display body never needs to become raycastable * again, and restoring the per-class prototype methods would be brittle. * * Interactive hover queries are unaffected: they run through a dedicated * proxy mesh kept outside the scene graph, not through `intersectObjects`. */ export declare function disableGroupRaycast(root: THREE.Object3D): void; /** * Walks up the scene graph to find which body index owns a given object. * Returns -1 when no match is found. */ export declare function findBodyIndex(obj: THREE.Object3D, bodies: RaycastBody[]): number; /** * Raycasts against all body groups and returns the first valid hit. * * Filtering rules: * - Hits beyond the body's radius are discarded (avoids mesh-edge false hits). * - When a focused body is provided, it is skipped as a candidate and used as * an occluder sphere — hits behind it are discarded. */ export declare function raycastBodies(raycaster: THREE.Raycaster, bodies: RaycastBody[], options?: RaycastBodiesOptions): RaycastHit | null; //# sourceMappingURL=bodyRaycast.d.ts.map