moop (#7594)
This commit is contained in:
@@ -22,8 +22,6 @@ public sealed partial class GameTicker
|
||||
|
||||
private static readonly string[] WhitelistedBackgroundExtensions = new string[] {"png", "jpg", "jpeg"};
|
||||
|
||||
private const string LobbyScreenPath = "/Textures/LobbyScreens";
|
||||
|
||||
private void InitializeLobbyBackground()
|
||||
{
|
||||
_lobbyBackgrounds = _prototypeManager.EnumeratePrototypes<LobbyBackgroundPrototype>()
|
||||
@@ -31,7 +29,11 @@ public sealed partial class GameTicker
|
||||
.Where(x => WhitelistedBackgroundExtensions.Contains(x.Extension))
|
||||
.ToList();
|
||||
|
||||
LobbyBackground = _lobbyBackgrounds.Any() ? _robustRandom.Pick(_lobbyBackgrounds).ToString() : null;
|
||||
RandomizeLobbyBackground();
|
||||
}
|
||||
|
||||
|
||||
private void RandomizeLobbyBackground() {
|
||||
LobbyBackground = _lobbyBackgrounds!.Any() ? _robustRandom.Pick(_lobbyBackgrounds!).ToString() : null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -348,6 +348,7 @@ namespace Content.Server.GameTicking
|
||||
|
||||
RunLevel = GameRunLevel.PreRoundLobby;
|
||||
LobbySong = _robustRandom.Pick(_lobbyMusicCollection.PickFiles).ToString();
|
||||
RandomizeLobbyBackground();
|
||||
ResettingCleanup();
|
||||
|
||||
if (!LobbyEnabled)
|
||||
|
||||
Reference in New Issue
Block a user