47 lines
1012 B
C
47 lines
1012 B
C
|
#pragma once
|
||
|
|
||
|
#include <Corrade/Utility/Configuration.h>
|
||
|
|
||
|
using namespace Corrade;
|
||
|
|
||
|
class Configuration {
|
||
|
public:
|
||
|
static Configuration& instance();
|
||
|
|
||
|
~Configuration();
|
||
|
|
||
|
void save();
|
||
|
|
||
|
int swapInterval() const;
|
||
|
void setSwapInterval(int interval);
|
||
|
|
||
|
float fpsCap() const;
|
||
|
void setFpsCap(float cap);
|
||
|
|
||
|
bool cheatMode() const;
|
||
|
void setCheatMode(bool enabled);
|
||
|
|
||
|
bool advancedMode() const;
|
||
|
void setAdvancedMode(bool enabled);
|
||
|
|
||
|
bool checkUpdatesOnStartup() const;
|
||
|
void setCheckUpdatesOnStartup(bool mode);
|
||
|
|
||
|
bool skipDisclaimer() const;
|
||
|
void setSkipDisclaimer(bool mode);
|
||
|
|
||
|
private:
|
||
|
explicit Configuration();
|
||
|
|
||
|
Utility::Configuration _conf;
|
||
|
|
||
|
int _swapInterval = 1;
|
||
|
float _fpsCap = 60.0f;
|
||
|
bool _cheatMode = false;
|
||
|
bool _advancedMode = false;
|
||
|
bool _checkUpdatesOnStartup = true;
|
||
|
bool _skipDisclaimer = false;
|
||
|
};
|
||
|
|
||
|
Configuration& conf();
|