import * as react_jsx_runtime from 'react/jsx-runtime'; import * as THREE from 'three'; import { GLTF } from 'three-stdlib'; import { RapierRigidBody } from '@react-three/rapier'; type ActionName = 'idle' | 'forwardWalk' | 'backwardWalk' | 'runForward' | 'runBackward' | 'strafeLeft' | 'strafeRight'; interface GLTFAction extends THREE.AnimationClip { name: ActionName; } type GLTFResult = GLTF & { nodes: { Slide_Highlight_0_1: THREE.Mesh; Slide_Highlight_0_2: THREE.Mesh; Slide_Highlight_0_3: THREE.Mesh; Alpha_Joints: THREE.SkinnedMesh; Alpha_Surface: THREE.SkinnedMesh; mixamorigHips: THREE.Bone; }; materials: { Highlight: THREE.MeshStandardMaterial; Primary: THREE.MeshStandardMaterial; Secondary: THREE.MeshStandardMaterial; Alpha_Joints_MAT: THREE.MeshStandardMaterial; Alpha_Body_MAT: THREE.MeshStandardMaterial; }; animations: GLTFAction[]; }; interface PlayerProps extends React.ComponentProps<'group'> { modelPath?: string; animationPaths?: { idle?: string; walkForward?: string; walkBackward?: string; runForward?: string; runBackward?: string; strafeLeft?: string; strafeRight?: string; jumpStart?: string; jumpEnd?: string; }; audioPath?: string; colliderArgs?: [height: number, radius: number]; mass?: number; restitution?: number; friction?: number; linearDamping?: number; angularDamping?: number; castShadow?: boolean; receiveShadow?: boolean; } interface PlayerState { wait: boolean; isJumping: boolean; action: THREE.AnimationAction | null; } interface PlayerRefs { group: React.RefObject; controls: React.RefObject; mouseRotationRef: React.MutableRefObject<{ x: number; y: number; }>; jumpPressedRef: React.MutableRefObject; shoot: React.MutableRefObject; zoom: React.MutableRefObject; shotSfxRef: React.RefObject; leftHandBone: React.MutableRefObject; rightHandBone: React.MutableRefObject; rightPalmBone: React.MutableRefObject; recoilActive: React.MutableRefObject; recoilStartTime: React.MutableRefObject; leftHandOriginalRotation: React.MutableRefObject; rightHandOriginalRotation: React.MutableRefObject; muzzleFlashRef: React.RefObject; muzzleFlashLightRef: React.RefObject; muzzleFlashActive: React.MutableRefObject; muzzleFlashStartTime: React.MutableRefObject; gunBarrelRef: React.MutableRefObject; smoothedPlayerPosition: React.MutableRefObject; smoothedCameraPosition: React.MutableRefObject; shootRayDirection: React.MutableRefObject; dotRef: React.RefObject; } interface JumpParams { jumpPressed: boolean; isGrounded: boolean; wait: boolean; isJumping: boolean; actions: THREE.AnimationAction[]; controls: React.RefObject; setAction: (action: THREE.AnimationAction) => void; setIsJumping: (jumping: boolean) => void; setWait: (wait: boolean) => void; } interface MovementParams { forward: boolean; backward: boolean; left: boolean; right: boolean; run: boolean; jump: boolean; wait: boolean; isJumping: boolean; actions: THREE.AnimationAction[]; setAction: (action: THREE.AnimationAction) => void; } interface RecoilParams { recoilActive: React.MutableRefObject; recoilStartTime: React.MutableRefObject; leftHandBone: React.MutableRefObject; rightHandBone: React.MutableRefObject; leftHandOriginalRotation: React.MutableRefObject; rightHandOriginalRotation: React.MutableRefObject; } interface MuzzleFlashParams { muzzleFlashActive: React.MutableRefObject; muzzleFlashStartTime: React.MutableRefObject; muzzleFlashRef: React.RefObject; muzzleFlashLightRef: React.RefObject; gunBarrelRef: React.MutableRefObject; group: React.RefObject; bones: THREE.Bone[]; pitch: number; yaw: number; camera: THREE.Camera; } interface CameraParams { zoom: React.MutableRefObject; smoothedPlayerPosition: React.MutableRefObject; smoothedCameraPosition: React.MutableRefObject; playerYRotation: THREE.Quaternion; pitch: number; yaw: number; camera: THREE.Camera; world?: any; } interface MovementPhysicsParams { forward: boolean; backward: boolean; left: boolean; right: boolean; run: boolean; playerYRotation: THREE.Quaternion; controls: React.RefObject; smoothedPlayerPosition: React.MutableRefObject; } declare function preloadPlayerAssets(modelPath?: string): void; declare function Player({ modelPath, animationPaths, audioPath, colliderArgs, mass, restitution, friction, linearDamping, angularDamping, castShadow, receiveShadow, ...props }: PlayerProps): react_jsx_runtime.JSX.Element; declare const MOVE_SPEED = 2; declare const RUN_MULTIPLIER = 2; declare const MOUSE_SENSITIVITY = 0.002; declare const RECOIL_STRENGTH = 0.1; declare const RECOIL_DURATION = 150; declare const MUZZLE_FLASH_DURATION = 50; declare const MUZZLE_FLASH_LIGHT_INTENSITY = 15; declare const MUZZLE_FLASH_LIGHT_DISTANCE = 8; declare const DEFAULT_CAMERA_FOV = 75; declare const ZOOM_CAMERA_FOV = 50; declare function handleMovement({ forward, backward, left, right, run, jump, wait, isJumping, actions, setAction }: MovementParams): boolean; declare function handleJump({ jumpPressed, isGrounded, wait, isJumping, actions, controls, setAction, setIsJumping, setWait }: JumpParams): void; declare function handleRecoil({ recoilActive, recoilStartTime, leftHandBone, rightHandBone, leftHandOriginalRotation, rightHandOriginalRotation }: RecoilParams): void; declare function handleMuzzleFlash({ muzzleFlashActive, muzzleFlashStartTime, muzzleFlashRef, muzzleFlashLightRef, gunBarrelRef, group, bones, pitch, yaw, camera }: MuzzleFlashParams): void; declare function updateCamera({ zoom, smoothedPlayerPosition, smoothedCameraPosition, playerYRotation, pitch, yaw, camera, world }: CameraParams): void; declare function updateMovementPhysics({ forward, backward, left, right, run, playerYRotation, controls, smoothedPlayerPosition }: MovementPhysicsParams): void; interface ShootingParams { world: any; camera: THREE.Camera; controls: React.RefObject; dotRef: React.RefObject; shoot: React.RefObject; shootRayDirection: React.RefObject; } declare function handleShooting({ world, camera, controls, dotRef, shoot, shootRayDirection }: ShootingParams): void; declare function createMuzzleFlashTexture(): THREE.CanvasTexture; interface AnimationPaths { idle?: string; walkForward?: string; walkBackward?: string; runForward?: string; runBackward?: string; strafeLeft?: string; strafeRight?: string; jumpStart?: string; jumpEnd?: string; } declare function useAnimationSetup(clone: THREE.Object3D, customAnimations?: AnimationPaths): { actions: THREE.AnimationAction[]; mixer: THREE.AnimationMixer; animationClips: THREE.AnimationClip[]; }; export { ActionName, CameraParams, DEFAULT_CAMERA_FOV, GLTFAction, GLTFResult, JumpParams, MOUSE_SENSITIVITY, MOVE_SPEED, MUZZLE_FLASH_DURATION, MUZZLE_FLASH_LIGHT_DISTANCE, MUZZLE_FLASH_LIGHT_INTENSITY, MovementParams, MovementPhysicsParams, MuzzleFlashParams, Player, PlayerProps, PlayerRefs, PlayerState, RECOIL_DURATION, RECOIL_STRENGTH, RUN_MULTIPLIER, RecoilParams, ZOOM_CAMERA_FOV, createMuzzleFlashTexture, handleJump, handleMovement, handleMuzzleFlash, handleRecoil, handleShooting, preloadPlayerAssets, updateCamera, updateMovementPhysics, useAnimationSetup };