group2 0.1.0
CSE 125 Group 2
Loading...
Searching...
No Matches
UserSettings Struct Reference

Per-user gameplay settings loaded from SDL's pref-path TOML file. More...

#include <UserSettings.hpp>

Collaboration diagram for UserSettings:
[legend]

Public Attributes

InputBindings inputBindings {InputBindings::defaults()}
 Configurable keyboard/mouse and controller bindings.
float mouseSensitivity {user_settings::kDefaultMouseSensitivity}
 Mouse-look sensitivity in radians per pixel.
float horizontalFovDegrees {110.0f}
 Player-facing horizontal camera FOV in degrees.
bool showControllerBindings {false}
 Settings page shows controller bindings when true.
float gamepadYawSensitivity
 radians/sec (30% below the old 6.0 base; look acceleration ramps it up on sustained turns)
float gamepadPitchSensitivity {4.2f}
float gamepadLookDeadzone {0.12f}
 Gamepad look deadzone radius in [0, 1]. Ignores stick drift out of the box.
float gamepadMoveDeadzone
 Gamepad move deadzone radius in [0, 1]. Higher than look — drift-walking is worse than drift-aim.
bool aimAssistEnabled {true}
float aimAssistStrength {1.0f}
 Aim assist strength in [0, 1], where 0 is no assist and 1 is full assist.
bool gamepadSwapSticks {false}
 If true, swap the left and right sticks for look and move input.
bool muzzleFlashEnabled {true}
 If false, suppress the dynamic muzzle-flash point light on weapon fire.
float musicVolume {0.7f}
 Music volume in [0, 1].
float sfxVolume {1.0f}
 Sound-effect volume in [0, 1].
std::string audioOutputDeviceName
 SDL playback device name; empty selects the system default.
std::string audioInputDeviceName
 SDL recording device name; empty selects the system default.

Detailed Description

Per-user gameplay settings loaded from SDL's pref-path TOML file.

Member Data Documentation

◆ aimAssistEnabled

bool UserSettings::aimAssistEnabled {true}

◆ aimAssistStrength

float UserSettings::aimAssistStrength {1.0f}

Aim assist strength in [0, 1], where 0 is no assist and 1 is full assist.

◆ audioInputDeviceName

std::string UserSettings::audioInputDeviceName

SDL recording device name; empty selects the system default.

◆ audioOutputDeviceName

std::string UserSettings::audioOutputDeviceName

SDL playback device name; empty selects the system default.

◆ gamepadLookDeadzone

float UserSettings::gamepadLookDeadzone {0.12f}

Gamepad look deadzone radius in [0, 1]. Ignores stick drift out of the box.

◆ gamepadMoveDeadzone

float UserSettings::gamepadMoveDeadzone
Initial value:
{
0.18f}

Gamepad move deadzone radius in [0, 1]. Higher than look — drift-walking is worse than drift-aim.

◆ gamepadPitchSensitivity

float UserSettings::gamepadPitchSensitivity {4.2f}

◆ gamepadSwapSticks

bool UserSettings::gamepadSwapSticks {false}

If true, swap the left and right sticks for look and move input.

◆ gamepadYawSensitivity

float UserSettings::gamepadYawSensitivity
Initial value:
{
4.2f}

radians/sec (30% below the old 6.0 base; look acceleration ramps it up on sustained turns)

◆ horizontalFovDegrees

float UserSettings::horizontalFovDegrees {110.0f}

Player-facing horizontal camera FOV in degrees.

◆ inputBindings

InputBindings UserSettings::inputBindings {InputBindings::defaults()}

Configurable keyboard/mouse and controller bindings.

◆ mouseSensitivity

float UserSettings::mouseSensitivity {user_settings::kDefaultMouseSensitivity}

Mouse-look sensitivity in radians per pixel.

◆ musicVolume

float UserSettings::musicVolume {0.7f}

Music volume in [0, 1].

◆ muzzleFlashEnabled

bool UserSettings::muzzleFlashEnabled {true}

If false, suppress the dynamic muzzle-flash point light on weapon fire.

◆ sfxVolume

float UserSettings::sfxVolume {1.0f}

Sound-effect volume in [0, 1].

◆ showControllerBindings

bool UserSettings::showControllerBindings {false}

Settings page shows controller bindings when true.


The documentation for this struct was generated from the following file: