summaryrefslogtreecommitdiff
path: root/intro_gui.c
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 /intro_gui.c
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 'intro_gui.c')
-rw-r--r--intro_gui.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/intro_gui.c b/intro_gui.c
index 9850f5f4c..13bb1958b 100644
--- a/intro_gui.c
+++ b/intro_gui.c
@@ -45,8 +45,8 @@ extern void HandleOnEditTextCancel(void);
static void SelectGameWndProc(Window *w, WindowEvent *e) {
switch(e->event) {
case WE_PAINT:
- w->click_state = (w->click_state & ~(0xC0) & ~(0xF << 12)) | (1 << (_new_opt.landscape+12)) | (1<<6);
- SetDParam(0, STR_6801_EASY + _new_opt.diff_level);
+ w->click_state = (w->click_state & ~(0xC0) & ~(0xF << 12)) | (1 << (_opt_newgame.landscape + 12)) | (1<<6);
+ SetDParam(0, STR_6801_EASY + _opt_newgame.diff_level);
DrawWindowWidgets(w);
break;
@@ -74,10 +74,6 @@ static void SelectGameWndProc(Window *w, WindowEvent *e) {
DoCommandP(0, e->click.widget - 12, 0, NULL, CMD_SET_NEW_LANDSCAPE_TYPE);
break;
}
- case WE_KEYPRESS:
- switch(e->keypress.keycode) {
- case WKC_BACKQUOTE: IConsoleSwitch(); break;
- }
break;
case WE_ON_EDIT_TEXT: HandleOnEditText(e); break;
@@ -293,8 +289,7 @@ void AskExitToGameMenu(void)
int32 CmdSetNewLandscapeType(int x, int y, uint32 flags, uint32 p1, uint32 p2)
{
if (flags & DC_EXEC) {
- // XXX: some stuff
- _new_opt.landscape = p1;
+ _opt_newgame.landscape = p1;
InvalidateWindowClasses(WC_SELECT_GAME);
}
return 0;