Skip to content

Commit

Permalink
Fix toggles not enabling when becoming lobby host
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-r-elp committed Aug 14, 2024
1 parent dbd9930 commit 813ae01
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/UI/MpPerPlayerUI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -198,10 +198,11 @@ namespace MultiplayerCore::UI {

void MpPerPlayerUI::UpdateButtonsEnabled() {
// UpdateButtonsEnabled
ppdt->set_interactable(_lobbyViewController->_isPartyOwner);
ppdt->text->alpha = _lobbyViewController->_isPartyOwner ? 1.0f : 0.25f;
ppmt->set_interactable(_lobbyViewController->_isPartyOwner);
ppmt->text->alpha = _lobbyViewController->_isPartyOwner ? 1.0f : 0.25f;
bool isPartyOwner = _gameServerLobbyFlowCoordinator->isPartyOwner;
ppdt->set_interactable(isPartyOwner);
ppdt->text->alpha = isPartyOwner ? 1.0f : 0.25f;
ppmt->set_interactable(isPartyOwner);
ppmt->text->alpha = isPartyOwner ? 1.0f : 0.25f;

// Request updated button states from server
_multiplayerSessionManager->Send(Players::Packets::GetMpPerPlayerPacket::New_ctor());
Expand Down

0 comments on commit 813ae01

Please sign in to comment.