Swimmer.component
README.md
Swimmer
Moves the body it sits on through water in three dimensions: the movement system of the abyssal.diver avatar. move (from moveMap, the default scheme) swims along the camera's view, its forward with its pitch so looking down and swimming forward dives, and its right; flyUp / flyDown (from verticalMap, the built-in flight scheme) rise and sink. With no vertical control held the body drifts down at drift, and the speed eases toward the controls at response, the way water slows a swimmer.
The body is a capsule (radius, height, standing on its feet) swept against every collider each frame, sliding along what it meets, so it keeps out of the seabed, rocks and set pieces of the world's collision proxy. It adds a MovementState beside itself when there is none, which Locomotion reads to face the body along its motion and blend its clips. Only the local player's body answers the controls; velocityX/Y/Z and touching report the last step.