File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -83,6 +83,7 @@ void AMyPlayerState::OnGameStateChanged(ECurrentGameState CurrentGameState)
8383 case ECurrentGameState::GameStarting:
8484 {
8585 EndGameStateInternal = EEndGameState::None;
86+ OnEndGameStateChanged.Broadcast (EndGameStateInternal);
8687 break ;
8788 }
8889 case ECurrentGameState::EndGame:
@@ -109,6 +110,7 @@ void AMyPlayerState::ServerUpdateEndState_Implementation()
109110 if (CurrentGameState == ECurrentGameState::EndGame) // game was finished
110111 {
111112 EndGameStateInternal = EEndGameState::Draw;
113+ OnEndGameStateChanged.Broadcast (EndGameStateInternal);
112114 return ;
113115 }
114116
Original file line number Diff line number Diff line change @@ -104,6 +104,8 @@ void UInGameMenuWidget::OnGameStateChanged(ECurrentGameState CurrentGameState)
104104// Called when the end-game state was changed
105105void UInGameMenuWidget::OnEndGameStateChanged (EEndGameState EndGameState)
106106{
107+ UpdateEndGameText ();
108+
107109 if (EndGameState != EEndGameState::None)
108110 {
109111 ShowInGameMenu ();
@@ -201,8 +203,6 @@ void UInGameMenuWidget::ShowInGameMenu()
201203 return ;
202204 }
203205
204- UpdateEndGameText ();
205-
206206 OnToggleInGameMenu (true );
207207
208208 // Blueprint implementation
You can’t perform that action at this time.
0 commit comments