camera.set_fov_preference
Overview
- Sets the user's camera field-of-view PREFERENCE, in degrees. Separate command from camera.set_fov because the argument means something else: this one takes the angle, that one takes the option system's 0-1 value. The value is the VERTICAL angle (AspectRatioAxisConstraint=AspectRatio_MaintainYFOV) and is rejected outside the range the option accepts, reported as fov_min/fov_max by camera.get_fov_preference and currently 30-75; it is not silently clamped, which is what camera.set_fov does. This does NOT change what any gameplay camera renders with. UB1CameraMode_Free::ComputeFOV and the follow family prefer UB1CameraJsonDataAsset.GameOptionPresetSetting.DefaultPresetMap for their mode and only fall back to this preference when there is no entry; ShoulderView and Free both have one, so in practice only the world map camera is affected. For a capture that has to render at a known field of view, use camera.observe_from_character fov_horizontal, which locks the camera manager instead. The value is written to GameUserSettings.ini and survives the process, so a caller that changes it owns putting it back.
Metadata
| Field | Value |
|---|---|
| Display | Set FOV Preference (degrees) |
| Category | camera |
| Access | ScriptCheat |
| Scope | B1Standalone |
| Tags | — |
| Aliases | — |
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| value | string | yes | — | Vertical FOV in degrees (e.g. 66). Rejected outside fov_min..fov_max |
Returns
Returns a JSON object with the following fields:
| Field | Type | Required | Description |
|---|---|---|---|
fov_deg | float | yes | Vertical FOV in degrees actually stored, read back after the write |
requested_fov_deg | float | yes | Vertical FOV in degrees that was asked for |
fov_min | float | yes | Smallest accepted FOV in degrees |
fov_max | float | yes | Largest accepted FOV in degrees |
fov_axis | string | yes | Which axis the value constrains; always vertical for this setting |
Usage
await inzoi.cli.execute('camera.set_fov_preference', {
value: '',
});