coastline 0.0.4
Loading...
Searching...
No Matches
configfile.h
Go to the documentation of this file.
1#pragma once
2
7
16
19 unsigned value;
20 const char *path;
21
23 ConfigLoadArgument(bool bAllowFailure) : value(bAllowFailure ? 1 : 0) {
24 }
25
26 ConfigLoadArgument(const char *pszPath) : path(pszPath) {
27 }
28};
29
36extern int g_dwConfigValue0;
37
44extern int g_dwConfigValue1;
45
52extern int g_bSpeedUnitsMph;
53
60extern const char g_szCRallyConfigDat[];
61
62#ifdef __cplusplus
63extern "C" {
64#endif
65
76bool LoadConfigData(int nConfigType, ConfigLoadArgument argument);
77#ifdef __cplusplus
78}
79#endif
int g_bSpeedUnitsMph
Whether the speed display uses miles per hour.
const char g_szCRallyConfigDat[]
The path used for binary configuration reads.
int g_dwConfigValue0
The first persisted configuration value, unused after loading.
bool LoadConfigData(int nConfigType, ConfigLoadArgument argument)
Load the selected profile, ghost, or binary configuration data.
int g_dwConfigValue1
The second persisted configuration value, unused after loading.
ConfigLoadType
The configuration sources accepted by LoadConfigData().
Definition configfile.h:9
@ CONFIG_LOAD_SEASON_FILE
Definition configfile.h:14
@ CONFIG_LOAD_EQUIPMENT
Definition configfile.h:12
@ CONFIG_LOAD_RAW
Definition configfile.h:13
@ CONFIG_LOAD_CURRENT_SEASON
Definition configfile.h:10
@ CONFIG_LOAD_GHOST
Definition configfile.h:11
The shared argument slot for an optional-load flag or a custom path.
Definition configfile.h:18
ConfigLoadArgument(const char *pszPath)
Construct an argument containing a custom path.
Definition configfile.h:26
const char * path
Definition configfile.h:20
unsigned value
Definition configfile.h:19
ConfigLoadArgument(bool bAllowFailure)
Construct a flag argument indicating whether failure is allowed.
Definition configfile.h:23