import type { Intersection } from "three"; import { Vector2, Vector3 } from "three"; import type { Emitter } from "../../core/emitter"; import type { Entity } from "../../core/Entity"; import { System } from "../../core/System"; import { ThreeObjectComponent } from "../components/graphics/ThreeObjectComponent"; import type { UI } from "../ui/index"; import type { ThreeGraphics } from "./ThreeGraphics"; export declare enum MouseButton { LEFT = 0, WHEEL = 1, RIGHT = 2, BACK = 3, FORWARD = 4 } export declare type MouseEvents = { mouseMove: (data: { mouse: Mouse; }) => void; mouseDown: (data: { button: MouseButton; ctrlDown: boolean; mouse: Mouse; }) => void; }; declare class Mouse extends System { static components: (typeof ThreeObjectComponent)[]; readonly pure = true; client: Vector2; /** Normalized coordinates from (-1 to 1) */ screen: Vector2; ground: Vector3; intersections: Intersection[]; target?: EventTarget; entity?: Entity; private mouseMoveListener; private mouseDownListener; private graphics; private raycaster; private mouseMoved; private ui; constructor(graphics: ThreeGraphics, ui: UI); dispose(): void; test(entity: Entity): entity is Entity; raycast(): void; preRender(): void; } interface Mouse extends Emitter { } export { Mouse };