From 0d7bd746ac4272fa5692df33c143a1f2b2ef9afb Mon Sep 17 00:00:00 2001 From: Catherine Reprobate Date: Mon, 21 Aug 2023 20:27:49 -0700 Subject: [PATCH] move abstracted n64 buttons to contants.h --- include/PR/os_cont.h | 30 ------------------------------ src/include/constants.h | 32 ++++++++++++++++++++++++++++++-- 2 files changed, 30 insertions(+), 32 deletions(-) diff --git a/include/PR/os_cont.h b/include/PR/os_cont.h index d176c7701..5d81bab62 100644 --- a/include/PR/os_cont.h +++ b/include/PR/os_cont.h @@ -171,36 +171,6 @@ typedef struct { #define CONT_ERR_VOICE_NO_RESPONSE 15 - - -#ifdef PLATFORM_N64 - -#define BUTTON_ACCEPT_WPNFORWARD CONT_A -#define BUTTON_CANCEL_USE CONT_B - -#define BUTTON_USE BUTTON_CANCEL_USE -#define BUTTON_CANCEL BUTTON_CANCEL_USE -#define BUTTON_RELOAD BUTTON_USE -#define BUTTON_ACCEPT BUTTON_ACCEPT_WPNFORWARD -#define BUTTON_WPNFORWARD BUTTON_ACCEPT_WPNFORWARD - -#else - -// xbla behavior -#define BUTTON_ACCEPT_USE A_BUTTON -// 1964 behavior -#define BUTTON_CANCEL_USE B_BUTTON - -#define BUTTON_RELOAD X_BUTTON -// dedicated button for mousewheel / xbla parity -#define BUTTON_WPNBACK L_JPAD -// dedicated button for mousewheel / xbla parity -#define BUTTON_WPNFORWARD Y_BUTTON -#define BUTTON_RADIAL D_JPAD -#define BUTTON_ALTMODE L_TRIG -#endif - - #if defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) /************************************************************************** diff --git a/src/include/constants.h b/src/include/constants.h index e5fc90f8c..7e96a2f68 100644 --- a/src/include/constants.h +++ b/src/include/constants.h @@ -4626,7 +4626,35 @@ enum weaponnum { #define BODY_DARK_LEATHER 0x95 #define BODY_DARK_NEGOTIATOR 0x96 -#endif - #define JO_ACTION_ACTIVATE 0x0001 #define JO_ACTION_RELOAD 0x0002 + + +#ifdef PLATFORM_N64 + +#define BUTTON_ACCEPT_WPNFORWARD CONT_A +#define BUTTON_CANCEL_USE CONT_B + +#define BUTTON_USE BUTTON_CANCEL_USE +#define BUTTON_CANCEL BUTTON_CANCEL_USE +#define BUTTON_RELOAD BUTTON_USE +#define BUTTON_ACCEPT BUTTON_ACCEPT_WPNFORWARD +#define BUTTON_WPNFORWARD BUTTON_ACCEPT_WPNFORWARD + +#else + +// xbla behavior +#define BUTTON_ACCEPT_USE A_BUTTON +// 1964 behavior +#define BUTTON_CANCEL_USE B_BUTTON + +#define BUTTON_RELOAD X_BUTTON +// dedicated button for mousewheel / xbla parity +#define BUTTON_WPNBACK L_JPAD +// dedicated button for mousewheel / xbla parity +#define BUTTON_WPNFORWARD Y_BUTTON +#define BUTTON_RADIAL D_JPAD +#define BUTTON_ALTMODE L_TRIG +#endif + +#endif