From 9088e3dbabd71cc696d93e28da0d31160e16da19 Mon Sep 17 00:00:00 2001 From: TehRealSalt Date: Fri, 9 Feb 2018 16:04:52 -0500 Subject: [PATCH] Slight adjustment --- src/g_game.c | 2 +- src/g_game.h | 1 + src/y_inter.c | 10 +++++----- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/g_game.c b/src/g_game.c index 9487c413..731b9d82 100644 --- a/src/g_game.c +++ b/src/g_game.c @@ -1139,7 +1139,7 @@ static INT32 Joy4Axis(axis_input_e axissel) return retaxis; } -static boolean InputDown(INT32 gc, UINT8 p) +boolean InputDown(INT32 gc, UINT8 p) { switch (p) { diff --git a/src/g_game.h b/src/g_game.h index b389f8fa..9a69fd12 100644 --- a/src/g_game.h +++ b/src/g_game.h @@ -92,6 +92,7 @@ ticcmd_t *G_MoveTiccmd(ticcmd_t* dest, const ticcmd_t* src, const size_t n); INT16 G_ClipAimingPitch(INT32 *aiming); INT16 G_SoftwareClipAimingPitch(INT32 *aiming); +boolean InputDown(INT32 gc, UINT8 p); INT32 JoyAxis(axis_input_e axissel, UINT8 p); extern angle_t localangle, localangle2, localangle3, localangle4; diff --git a/src/y_inter.c b/src/y_inter.c index ec1b7196..6895f5a3 100644 --- a/src/y_inter.c +++ b/src/y_inter.c @@ -2290,7 +2290,7 @@ void Y_VoteTicker(void) UINT8 tempvotes[MAXPLAYERS]; UINT8 numvotes = 0; - if (votetic % (TICRATE/7) != 0) + if (votetic % (TICRATE/3) != 0) return; for (i = 0; i < MAXPLAYERS; i++) @@ -2301,7 +2301,7 @@ void Y_VoteTicker(void) numvotes++; } - randomanim = tempvotes[((pickedvote + ((voteendtic-votetic) / (TICRATE/7))) % numvotes)]; + randomanim = tempvotes[((pickedvote + ((voteendtic-votetic) / (TICRATE/3))) % numvotes)]; S_StartSound(NULL, sfx_s3k5b); } else @@ -2320,12 +2320,12 @@ void Y_VoteTicker(void) D_ModifyClientVote(-1); else if (pickedvote == -1 && votes[consoleplayer] == -1 && !voteclient.delay) { - if (PLAYER1INPUTDOWN(gc_aimforward) || JoyAxis(AXISMOVE, 1) < 0) + if (InputDown(gc_aimforward, 1) || JoyAxis(AXISMOVE, 1) < 0) { voteclient.selection--; pressed = true; } - if ((PLAYER1INPUTDOWN(gc_aimbackward) || JoyAxis(AXISMOVE, 1) > 0) && !pressed) + if ((InputDown(gc_aimbackward, 1) || JoyAxis(AXISMOVE, 1) > 0) && !pressed) { voteclient.selection++; pressed = true; @@ -2334,7 +2334,7 @@ void Y_VoteTicker(void) voteclient.selection = 3; if (voteclient.selection > 3) voteclient.selection = 0; - if (PLAYER1INPUTDOWN(gc_accelerate) && !pressed) + if (InputDown(gc_accelerate, 1) && !pressed) { D_ModifyClientVote(voteclient.selection); pressed = true;