Camera (Smash Hit)¶
This module allows to offset the position and rotation of the game’s camera by a certian amount, relative to wherever the game currently places the camera. It also allows adjusting the field of view.
Added in version 22: The purple has forced my paw.
-
knCameraPosOffset(x:
number, y:number, z:number)¶ Set the camera position offset.
- Parameters:
x – Left and right offset (right is positive)
y – Up and down offset (up is positive)
z – Back and forward offset (forward is negative)
Note
This function does not adjust the position at which the balls are thrown and collision is checked. For that, consider using Amethyst Patcher.
-
knCameraRotOffset(x:
number, y:number, z:number)¶ Adjust the camera rotation offset. All angles are in radians.
- Parameters:
x – Rotation as if looking left or right
y – Rotation as if looking up or down
z – Roll
Warning
While this function does change the angle at which balls are shot, it is a bit buggy according to KD.
-
knCameraFov(fovY:
number)¶ Set the camera’s vertical field of view to
fovYin degrees.