summaryrefslogtreecommitdiff
path: root/src/setup/keyboard.c
diff options
context:
space:
mode:
authorSimon Howard2008-11-24 19:01:09 +0000
committerSimon Howard2008-11-24 19:01:09 +0000
commit2f67325278637a349bb86fa6fc388e527a75a5c9 (patch)
tree43654566eb557d5f909ed45b16b86c3346a1798c /src/setup/keyboard.c
parent09f98f80fc8ed9e42ea937804618952f03244bde (diff)
downloadchocolate-doom-2f67325278637a349bb86fa6fc388e527a75a5c9.tar.gz
chocolate-doom-2f67325278637a349bb86fa6fc388e527a75a5c9.tar.bz2
chocolate-doom-2f67325278637a349bb86fa6fc388e527a75a5c9.zip
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
Diffstat (limited to 'src/setup/keyboard.c')
-rw-r--r--src/setup/keyboard.c20
1 files changed, 8 insertions, 12 deletions
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);
+}
+