Skip to content

Commit

Permalink
Fix #476 directly
Browse files Browse the repository at this point in the history
  • Loading branch information
NQNStudios authored and CelticMinstrel committed Nov 23, 2024
1 parent b2c0af3 commit 6d6f25f
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/game/boe.startup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,9 @@ void handle_startup_button_click(eStartButton btn, eKeyMod mods) {
case STARTBTN_JOIN:
if(!party_in_memory) {
if(mod_contains(mods, mod_alt)) {
// This is a special case fix for issue #476:
kb.flushModifiers();

force_party = true;
start_new_game(true);
} else {
Expand Down
7 changes: 7 additions & 0 deletions src/tools/keymods.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -91,3 +91,10 @@ bool keymods_t::handleModifier(const sf::Event& evt) {
}
return true;
}

void keymods_t::flushModifiers() {
alt = false;
ctrl = false,
shift = false,
meta = false;
}
1 change: 1 addition & 0 deletions src/tools/keymods.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ class keymods_t {
bool isLeftPressed() const;
bool isRightPressed() const;
bool handleModifier(const sf::Event& evt);
void flushModifiers();
};

extern keymods_t kb;
Expand Down

0 comments on commit 6d6f25f

Please sign in to comment.