Small cleanup.

This commit is contained in:
Themaister 2011-09-06 19:53:22 +02:00
parent be5acff69c
commit 32a5460ea7
4 changed files with 7 additions and 5 deletions

View File

@ -224,7 +224,7 @@ static const bool netplay_client_swap_input = true;
// Axis threshold (between 0.0 and 1.0)
// How far an axis must be tilted to result in a button press
#define AXIS_THRESHOLD 0.5
static const float axis_threshold = 0.5;
// To figure out which joypad buttons to use, check jstest or similar.
// SDL sometimes reverses the axes for some odd reason, but hey. :D

View File

@ -27,7 +27,7 @@
enum
{
SSNES_FAST_FORWARD_KEY = 0x666, // Hurr, durr
SSNES_FAST_FORWARD_KEY = 12, // SNES has 12 buttons from 0-11 (libsnes.hpp)
SSNES_FAST_FORWARD_HOLD_KEY,
SSNES_LOAD_STATE_KEY,
SSNES_SAVE_STATE_KEY,
@ -47,7 +47,9 @@ enum
SSNES_CHEAT_INDEX_MINUS,
SSNES_CHEAT_TOGGLE,
SSNES_SCREENSHOT,
SSNES_DSP_CONFIG
SSNES_DSP_CONFIG,
SSNES_BIND_LIST_END
};

View File

@ -55,7 +55,7 @@
#endif
#define MAX_PLAYERS 5
#define MAX_BINDS 34 // Needs to be increased every time there are new binds added.
#define MAX_BINDS (SSNES_BIND_LIST_END + 1)
#define SSNES_NO_JOYPAD 0xFFFF
enum ssnes_shader_type

View File

@ -176,7 +176,7 @@ static void set_defaults(void)
for (unsigned i = 1; i < 5; i++)
memcpy(g_settings.input.binds[i], snes_keybinds_rest, sizeof(snes_keybinds_rest));
g_settings.input.axis_threshold = AXIS_THRESHOLD;
g_settings.input.axis_threshold = axis_threshold;
g_settings.input.netplay_client_swap_input = netplay_client_swap_input;
for (int i = 0; i < MAX_PLAYERS; i++)
g_settings.input.joypad_map[i] = i;