From 2f67325278637a349bb86fa6fc388e527a75a5c9 Mon Sep 17 00:00:00 2001 From: Simon Howard Date: Mon, 24 Nov 2008 19:01:09 +0000 Subject: Make chocolate-setup use m_controls.c definitions for config file keyboard/mouse/joystick variables. Make other configuration file variables static and add bind functions. Subversion-branch: /branches/raven-branch Subversion-revision: 1387 --- src/setup/keyboard.c | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) (limited to 'src/setup/keyboard.c') diff --git a/src/setup/keyboard.c b/src/setup/keyboard.c index 3a7ccb8f..908e5c7a 100644 --- a/src/setup/keyboard.c +++ b/src/setup/keyboard.c @@ -20,6 +20,8 @@ // #include "textscreen.h" #include "doomtype.h" +#include "m_config.h" +#include "m_controls.h" #include "execute.h" #include "txt_keyinput.h" @@ -27,18 +29,7 @@ #include "joystick.h" #include "keyboard.h" -int key_left = KEY_LEFTARROW; -int key_right = KEY_RIGHTARROW; -int key_up = KEY_UPARROW; -int key_down = KEY_DOWNARROW; -int key_strafeleft = ','; -int key_straferight = '.'; -int key_fire = KEY_RCTRL; -int key_use = ' '; -int key_strafe = KEY_RALT; -int key_speed = KEY_RSHIFT; - -int vanilla_keyboard_mapping = 1; +static int vanilla_keyboard_mapping = 1; static int always_run = 0; @@ -141,3 +132,8 @@ void ConfigKeyboard(void) TXT_SetWindowAction(window, TXT_HORIZ_CENTER, TestConfigAction()); } +void BindKeyboardVariables(void) +{ + M_BindVariable("vanilla_keyboard_mapping", &vanilla_keyboard_mapping); +} + -- cgit v1.2.3