early-access version 3962
This commit is contained in:
@@ -1108,9 +1108,9 @@ Result Controller_NPad::DisconnectNpad(Core::HID::NpadIdType npad_id) {
|
||||
shared_memory->sixaxis_dual_right_properties.raw = 0;
|
||||
shared_memory->sixaxis_left_properties.raw = 0;
|
||||
shared_memory->sixaxis_right_properties.raw = 0;
|
||||
shared_memory->battery_level_dual = 0;
|
||||
shared_memory->battery_level_left = 0;
|
||||
shared_memory->battery_level_right = 0;
|
||||
shared_memory->battery_level_dual = Core::HID::NpadBatteryLevel::Empty;
|
||||
shared_memory->battery_level_left = Core::HID::NpadBatteryLevel::Empty;
|
||||
shared_memory->battery_level_right = Core::HID::NpadBatteryLevel::Empty;
|
||||
shared_memory->fullkey_color = {
|
||||
.attribute = ColorAttribute::NoController,
|
||||
.fullkey = {},
|
||||
|
||||
@@ -32,15 +32,15 @@ struct Lifo {
|
||||
}
|
||||
|
||||
std::size_t GetPreviousEntryIndex() const {
|
||||
return static_cast<size_t>((buffer_tail + total_buffer_count - 1) % total_buffer_count);
|
||||
return static_cast<size_t>((buffer_tail + max_buffer_size - 1) % max_buffer_size);
|
||||
}
|
||||
|
||||
std::size_t GetNextEntryIndex() const {
|
||||
return static_cast<size_t>((buffer_tail + 1) % total_buffer_count);
|
||||
return static_cast<size_t>((buffer_tail + 1) % max_buffer_size);
|
||||
}
|
||||
|
||||
void WriteNextEntry(const State& new_state) {
|
||||
if (buffer_count < total_buffer_count - 1) {
|
||||
if (buffer_count < static_cast<s64>(max_buffer_size) - 1) {
|
||||
buffer_count++;
|
||||
}
|
||||
buffer_tail = GetNextEntryIndex();
|
||||
|
||||
Reference in New Issue
Block a user