2024-06-04 23:12:43 +00:00
|
|
|
#ifndef __ZELDA_CONFIG_H__
|
|
|
|
#define __ZELDA_CONFIG_H__
|
|
|
|
|
|
|
|
#include <filesystem>
|
|
|
|
#include <string_view>
|
|
|
|
#include "ultramodern/config.hpp"
|
2024-07-06 01:19:31 +00:00
|
|
|
#include "recomp_input.h"
|
2024-06-04 23:12:43 +00:00
|
|
|
|
|
|
|
namespace zelda64 {
|
|
|
|
constexpr std::u8string_view program_id = u8"Zelda64Recompiled";
|
|
|
|
constexpr std::string_view program_name = "Zelda 64: Recompiled";
|
|
|
|
|
|
|
|
// TODO: Move loading configs to the runtime once we have a way to allow per-project customization.
|
|
|
|
void load_config();
|
|
|
|
void save_config();
|
|
|
|
|
|
|
|
void reset_input_bindings();
|
|
|
|
void reset_cont_input_bindings();
|
|
|
|
void reset_kb_input_bindings();
|
2024-07-06 01:19:31 +00:00
|
|
|
void reset_single_input_binding(recomp::InputDevice device, recomp::GameInput input);
|
2024-06-04 23:12:43 +00:00
|
|
|
|
|
|
|
std::filesystem::path get_app_folder_path();
|
|
|
|
|
|
|
|
bool get_debug_mode_enabled();
|
|
|
|
void set_debug_mode_enabled(bool enabled);
|
|
|
|
|
|
|
|
enum class AutosaveMode {
|
|
|
|
On,
|
|
|
|
Off,
|
|
|
|
OptionCount
|
|
|
|
};
|
|
|
|
|
|
|
|
NLOHMANN_JSON_SERIALIZE_ENUM(zelda64::AutosaveMode, {
|
|
|
|
{zelda64::AutosaveMode::On, "On"},
|
|
|
|
{zelda64::AutosaveMode::Off, "Off"}
|
|
|
|
});
|
|
|
|
|
2024-07-23 04:34:35 +00:00
|
|
|
AutosaveMode get_autosave_mode();
|
|
|
|
void set_autosave_mode(AutosaveMode mode);
|
|
|
|
|
2024-06-04 23:12:43 +00:00
|
|
|
enum class TargetingMode {
|
|
|
|
Switch,
|
|
|
|
Hold,
|
|
|
|
OptionCount
|
|
|
|
};
|
|
|
|
|
|
|
|
NLOHMANN_JSON_SERIALIZE_ENUM(zelda64::TargetingMode, {
|
|
|
|
{zelda64::TargetingMode::Switch, "Switch"},
|
|
|
|
{zelda64::TargetingMode::Hold, "Hold"}
|
|
|
|
});
|
|
|
|
|
|
|
|
TargetingMode get_targeting_mode();
|
|
|
|
void set_targeting_mode(TargetingMode mode);
|
|
|
|
|
|
|
|
enum class CameraInvertMode {
|
|
|
|
InvertNone,
|
|
|
|
InvertX,
|
|
|
|
InvertY,
|
|
|
|
InvertBoth,
|
|
|
|
OptionCount
|
|
|
|
};
|
|
|
|
|
|
|
|
NLOHMANN_JSON_SERIALIZE_ENUM(zelda64::CameraInvertMode, {
|
|
|
|
{zelda64::CameraInvertMode::InvertNone, "InvertNone"},
|
|
|
|
{zelda64::CameraInvertMode::InvertX, "InvertX"},
|
|
|
|
{zelda64::CameraInvertMode::InvertY, "InvertY"},
|
|
|
|
{zelda64::CameraInvertMode::InvertBoth, "InvertBoth"}
|
|
|
|
});
|
|
|
|
|
|
|
|
CameraInvertMode get_camera_invert_mode();
|
|
|
|
void set_camera_invert_mode(CameraInvertMode mode);
|
|
|
|
|
|
|
|
CameraInvertMode get_analog_camera_invert_mode();
|
|
|
|
void set_analog_camera_invert_mode(CameraInvertMode mode);
|
|
|
|
|
|
|
|
enum class AnalogCamMode {
|
|
|
|
On,
|
|
|
|
Off,
|
|
|
|
OptionCount
|
|
|
|
};
|
|
|
|
|
|
|
|
NLOHMANN_JSON_SERIALIZE_ENUM(zelda64::AnalogCamMode, {
|
|
|
|
{zelda64::AnalogCamMode::On, "On"},
|
|
|
|
{zelda64::AnalogCamMode::Off, "Off"}
|
|
|
|
});
|
|
|
|
|
|
|
|
AnalogCamMode get_analog_cam_mode();
|
|
|
|
void set_analog_cam_mode(AnalogCamMode mode);
|
|
|
|
|
2024-07-23 04:34:35 +00:00
|
|
|
enum class SpecialItemHudMode {
|
|
|
|
On,
|
|
|
|
Off,
|
|
|
|
OptionCount
|
|
|
|
};
|
|
|
|
|
|
|
|
NLOHMANN_JSON_SERIALIZE_ENUM(zelda64::SpecialItemHudMode, {
|
|
|
|
{zelda64::SpecialItemHudMode::On, "On"},
|
|
|
|
{zelda64::SpecialItemHudMode::Off, "Off"}
|
|
|
|
});
|
|
|
|
|
|
|
|
SpecialItemHudMode get_special_item_hud_mode();
|
|
|
|
void set_special_item_hud_mode(SpecialItemHudMode mode);
|
|
|
|
|
2024-06-04 23:12:43 +00:00
|
|
|
void open_quit_game_prompt();
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|