Перейти к содержанию

Camera::setFov

Материал из RAGE MP Wiki Archive

Sets the field of view of the camera.
---------------------------------------------
Min: 1.0f
Max: 130.0f

Syntax

<syntaxhighlight lang="javascript">camera.setFov(fieldOfView);</syntaxhighlight>

Required Arguments

  • fieldOfView: float

Return value

  • Undefined

Example

<syntaxhighlight lang="javascript"> let camera = mp.cameras.new('default', new mp.Vector3(-485, 1095.75, 323.85), new mp.Vector3(0,0,0), 40); // Creates the camera camera.setActive(true);

camera.setFov(15); // Sets the Field of View of the camera to 15 </syntaxhighlight>

See also