______________________________

Extended Camera Settings Readme
_______________________________

-- Requirements --

ScriptHookV - http://www.dev-c.com/gtav/scripthookv
Microsoft Visual C++ Redistributable (2015) https://www.microsoft.com/en-ca/download/details.aspx?id=48145

Installation:
Move ExtendedCameraSettings.asi to your GTA installation folder.

-- Default keybinds --

Save camera settings : Control + B

Reload camera settings : F11

-- Usage --

Most settings can be changed in- game through the camera section of the settings menu (in the pause menu) and will be automatically saved back to the xml file so long as the 'AutoSaveLayouts' option is enabled in the ExtendedCameraSettings.INI file.

If the option is disabled, presets will have to be saved manually by holding down the control key in addition to the key specified under "ReloadSettings" in the "KeyBinds" section of the .INI file. The game should show a notification if the file was succesfully updated.

In the case you want to update settings from the XML file to the game, you will need to press the key assigned to the "ReloadSettings" option in the .INI file. Doing so will reload all values from the file and show a notification if the operation completed succesfully.

For more fine tuned control over camera setting values, you can always add or edit the presets in the .xml file manually.

-- Information on structuring of the XML file --

Entries in the XML file should follow the following format

  <camPreset>
    <modelName>0</modelName>
    ( camera specific preset data goes here... )
  <camPreset>

Where "modelname" is the name of the vehicle or ped that will receive the modified camera settings. This would be the same name entered in a trainer with a "manual spawn" feature i.e. "lazer". Alternatively, this can be the JOAAT hash of the string in hexidecimal form i.e. "0xB39B0AE6".

Since peds and vehicles can use many different camera types (third- person, first- person etc.), each cameraPreset entry must also define a nested section for the camera that is being modified.

The format of this section should look similar to this:

<firstPersonPedCam>
      <Preset name="fov" type="float">45</Preset>
</firstPersonPedCam>

This section is where the actual settings for the camera are stored by the mod. The name of the section coorresponds to the type of camera (third-person, first-person, third-person-vehicle etc.) that is being modified and should be relevant to the model name that the <camPreset> section has defined.

For example, an entry with a ped model specified under <modelName> should specify one or more of the following camera types:

"thirdPersonPedCam"
"firstPersonPedCam"
"thirdPersonAimCam"

while vehicles have the following camera types available to them:

"thirdPersonVehicleCam"
"firstPersonVehicleCam"

Using a camera type that is not associated with the model may result in undefined behaviour. So don't use vehicle camera types on peds and vise-versa.

Following is all the presets that can be specified for each individual camera type. Keep in mind that many of these are based on pure RE and may not accurately represent the actual names for the associated parameters. Although, I will not add settings to this list until I have a reasonable understanding of their specific purpose. 

Further documentation/ information about these settings can be seen in the example "CameraPresets.xml" file in the example folder.

Third person player/ ped camera ("thirdPersonPedCam") -->

"fov" - Camera field of view
"sprintShakeSpeed" - The speed when the camera begins to shake, while sprinting
"minPitch" - Minimum view angle of the camera
"maxPitch" - Maximum view angle of the camera
"pivotOffsetX" - Horizontal adjustment of the camera position
"followDistance" - Distance of the camera behind the player 

Third person player/ ped aiming camera ("thirdPersonAimCam") -->

"fov" - Camera field of view
"pivotOffsetX" - Horizontal adjustment of the camera position
"followDistance" - Distance of the camera behind the player

First person player/ ped camera ("firstPersonPedCam") -->

"fov" - Camera field of view
"minPitch" - Minimum view angle of the camera
"maxPitch" - Maximum view angle of the camera
"alwaysUseReticle" - Whether to use a reticle when using non- lethal weapons or drawing your fists
"viewOffsetX" - Horizontal adjustment of the camera position
"viewOffsetY" - Forward adjustment of the camera position
"viewOffsetZ" - Vertical adjustment of the camera position
"altMinYaw" - Alternative minimum yaw value
"altMaxYaw" - Alternative maximum yaw value
"altMinPitch" - Alternative minimum pitch value
"altMaxPitch" - Alternative maximum pitch value

First person in- vehicle camera ("firstPersonVehicleCam") -->

"fov" - Camera field of view
"minPitch" - Minimum view angle of the camera
"maxPitch" - Maximum view angle of the camera
"minPitchExt" - Extended minimum view angle of the camera
"maxPitchExt" - Extended maximum view angle of the camera
"minSpeedForAutoCorrect" - Minimum speed at which the camera will begin to auto- correct to the front
"viewOffsetX" - Horizontal adjustment of the camera position
"viewOffsetY" - Forward adjustment of the camera position
"viewOffsetZ" - Vertical adjustment of the camera position

Third person vehicle camera ("thirdPersonVehicleCam") -->

"fov" - Camera field of view
"highSpeedShakeSpeed" - Minimum speed at which the camera will begin to shake
"enableAutoCenter" - Toggle auto- centering of the camera
"autoCenterLerpScale" - Adjusts the speed of rotation when auto- centering
"followDistance" - Distance of the camera behind the vehicle
"pivotScale" - The scale of "rolling" rotation when rotating the camera above the bounding box of the vehicle
"pivotOffsetX" - Horizontal adjustment of the camera position
"speedZoomStartSpeed" - Speed at which the camera begins to move away from the vehicle for "speed- relative zooming" functions
"speedZoomEndSpeed" - Speed at which the camera will be at the furthest distance behind the vehicle
