summaryrefslogtreecommitdiff
path: root/variables.h
diff options
context:
space:
mode:
authorDarkvater <darkvater@openttd.org>2005-03-12 21:21:47 +0000
committerDarkvater <darkvater@openttd.org>2005-03-12 21:21:47 +0000
commit010d1a9be338ec98a1e2ff50ec5b39d309a477ef (patch)
tree3e154dae321b4ae4880a4ae3ad91616338e7b720 /variables.h
parentc3f9f5efafea127f1dd8e64b627033de3aa44ac8 (diff)
downloadopenttd-010d1a9be338ec98a1e2ff50ec5b39d309a477ef.tar.xz
(svn r2004) - Fix: [ 1149487 ] Autosave ignoring settings
- Fix: [ 1153926 ] All my settings in vain... IGNORED! - Change: I hope I got it all right. Pressing 'New Game' (either choosing random or a preset scenario) and 'Create Scenario' will start a new game with the settings and difficulty in the intro menu. Using 'Load Game' and 'Play Scenario' will take the values from the savegame/scenario itself.
Diffstat (limited to 'variables.h')
-rw-r--r--variables.h28
1 files changed, 11 insertions, 17 deletions
diff --git a/variables.h b/variables.h
index 3149f827b..575f7920e 100644
--- a/variables.h
+++ b/variables.h
@@ -2,11 +2,8 @@
#define VARIABLES_H
#include "player.h"
-//enum { DPARAM_SIZE = 32 };
-
// ********* START OF SAVE REGION
-
#if !defined(MAX_PATH)
# define MAX_PATH 260
#endif
@@ -32,11 +29,15 @@ typedef struct {
byte road_side;
} GameOptions;
-// These are the options for the current game
+/* These are the options for the current game
+ * either ingame, or loaded. Also used for networking games */
VARDEF GameOptions _opt;
-// These are the options for the new game
-VARDEF GameOptions _new_opt;
+/* These are the default options for a new game */
+VARDEF GameOptions _opt_newgame;
+
+// Pointer to one of the two _opt OR _opt_newgame structs
+VARDEF GameOptions *_opt_ptr;
enum {
CF_NOEURO = 0,
@@ -242,10 +243,6 @@ typedef struct Paths {
VARDEF Paths _path;
-// Which options struct does options modify?
-VARDEF GameOptions *_opt_mod_ptr;
-VARDEF GameOptions _opt_mod_temp;
-
// NOSAVE: Used in palette animations only, not really important.
VARDEF int _timer_counter;
@@ -331,19 +328,16 @@ VARDEF char _savedump_path[64];
VARDEF uint _savedump_first, _savedump_freq, _savedump_last;
// end of debug features
-
-typedef struct {
- char *name;
- char *file;
-} DynLangEnt;
-
// Used for dynamic language support
typedef struct {
int num; // number of languages
int curr; // currently selected language index
char curr_file[32]; // currently selected language file
StringID dropdown[32 + 1]; // used in settings dialog
- DynLangEnt ent[32];
+ struct {
+ char *name;
+ char *file;
+ } ent[32];
} DynamicLanguages;
VARDEF DynamicLanguages _dynlang;