summaryrefslogtreecommitdiff
path: root/src/input_common/drivers/tas_input.h
diff options
context:
space:
mode:
authorGravatar german772021-10-30 20:16:10 -0500
committerGravatar Narr the Reg2021-11-24 20:30:26 -0600
commit61d9eb9f690d6afe141f24ba75c99b54e122dfa3 (patch)
tree895bee43d85f4013ce9c45e7d89b67e923888246 /src/input_common/drivers/tas_input.h
parentcore/hid: Explain better what a temporary value does (diff)
downloadyuzu-61d9eb9f690d6afe141f24ba75c99b54e122dfa3.tar.gz
yuzu-61d9eb9f690d6afe141f24ba75c99b54e122dfa3.tar.xz
yuzu-61d9eb9f690d6afe141f24ba75c99b54e122dfa3.zip
input_common: Revert deleted TAS functions
Diffstat (limited to 'src/input_common/drivers/tas_input.h')
-rw-r--r--src/input_common/drivers/tas_input.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/input_common/drivers/tas_input.h b/src/input_common/drivers/tas_input.h
index 9fadc118b..5f5c3267c 100644
--- a/src/input_common/drivers/tas_input.h
+++ b/src/input_common/drivers/tas_input.h
@@ -47,7 +47,7 @@ namespace InputCommon::TasInput {
47 47
48constexpr size_t PLAYER_NUMBER = 10; 48constexpr size_t PLAYER_NUMBER = 10;
49 49
50enum class TasButton : u32 { 50enum class TasButton : u64 {
51 BUTTON_A = 1U << 0, 51 BUTTON_A = 1U << 0,
52 BUTTON_B = 1U << 1, 52 BUTTON_B = 1U << 1,
53 BUTTON_X = 1U << 2, 53 BUTTON_X = 1U << 2,
@@ -92,7 +92,7 @@ public:
92 * @param left_axis: value of the left axis 92 * @param left_axis: value of the left axis
93 * @param right_axis: value of the right axis 93 * @param right_axis: value of the right axis
94 */ 94 */
95 void RecordInput(u32 buttons, TasAnalog left_axis, TasAnalog right_axis); 95 void RecordInput(u64 buttons, TasAnalog left_axis, TasAnalog right_axis);
96 96
97 // Main loop that records or executes input 97 // Main loop that records or executes input
98 void UpdateThread(); 98 void UpdateThread();
@@ -129,7 +129,7 @@ public:
129 129
130private: 130private:
131 struct TASCommand { 131 struct TASCommand {
132 u32 buttons{}; 132 u64 buttons{};
133 TasAnalog l_axis{}; 133 TasAnalog l_axis{};
134 TasAnalog r_axis{}; 134 TasAnalog r_axis{};
135 }; 135 };
@@ -164,9 +164,9 @@ private:
164 * Parses a string containing the button values. Each button is represented by it's text format 164 * Parses a string containing the button values. Each button is represented by it's text format
165 * specified in text_to_tas_button array 165 * specified in text_to_tas_button array
166 * @param line: string containing button name with the following format "a;b;c;d..." 166 * @param line: string containing button name with the following format "a;b;c;d..."
167 * @return Returns a u32 with each bit representing the status of a button 167 * @return Returns a u64 with each bit representing the status of a button
168 */ 168 */
169 u32 ReadCommandButtons(const std::string& line) const; 169 u64 ReadCommandButtons(const std::string& line) const;
170 170
171 /** 171 /**
172 * Reset state of all players 172 * Reset state of all players
@@ -174,11 +174,11 @@ private:
174 void ClearInput(); 174 void ClearInput();
175 175
176 /** 176 /**
177 * Converts an u32 containing the button status into the text equivalent 177 * Converts an u64 containing the button status into the text equivalent
178 * @param buttons: bitfield with the status of the buttons 178 * @param buttons: bitfield with the status of the buttons
179 * @return Returns a string with the name of the buttons to be written to the file 179 * @return Returns a string with the name of the buttons to be written to the file
180 */ 180 */
181 std::string WriteCommandButtons(u32 buttons) const; 181 std::string WriteCommandButtons(u64 buttons) const;
182 182
183 /** 183 /**
184 * Converts an TAS analog object containing the axis status into the text equivalent 184 * Converts an TAS analog object containing the axis status into the text equivalent