diff --git a/Blaster.uproject b/Blaster.uproject index 673f04d..1f5ca31 100644 --- a/Blaster.uproject +++ b/Blaster.uproject @@ -22,6 +22,10 @@ "Editor" ] }, + { + "Name": "OnlineSubsystemSteam", + "Enabled": true + }, { "Name": "Bridge", "Enabled": true, diff --git a/Content/Maps/GameStartupMap.umap b/Content/Maps/GameStartupMap.umap index 5e0ba6f..c26e038 100644 Binary files a/Content/Maps/GameStartupMap.umap and b/Content/Maps/GameStartupMap.umap differ diff --git a/Source/Blaster/PlayerController/BlasterPlayerController.cpp b/Source/Blaster/PlayerController/BlasterPlayerController.cpp index d71a128..09ad565 100644 --- a/Source/Blaster/PlayerController/BlasterPlayerController.cpp +++ b/Source/Blaster/PlayerController/BlasterPlayerController.cpp @@ -225,6 +225,16 @@ void ABlasterPlayerController::SetHUDTime() else if (MatchState == MatchState::Cooldown) TimeLeft = CooldownTime + WarmupTime + MatchTime - GetServerTime() + LevelStartingTime; uint32 SecondsLeft = FMath::CeilToInt(TimeLeft); + + if (HasAuthority()) + { + BlasterGameMode = BlasterGameMode == nullptr ? Cast(UGameplayStatics::GetGameMode(this)) : BlasterGameMode; + if (BlasterGameMode) + { + SecondsLeft = FMath::CeilToInt(BlasterGameMode->GetCountdownTime() + LevelStartingTime); + } + } + if (CountdownInt != SecondsLeft) { if (MatchState == MatchState::WaitingToStart || MatchState == MatchState::Cooldown)