Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion RLBotCS/Main.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
if (args.Length > 0 && args[0] == "--version")
{
Console.WriteLine(
"RLBotServer v5.beta.7.6\n"
"RLBotServer v5.beta.7.7\n"
+ $"Bridge {BridgeVersion.Version}\n"
+ "@ https://www.rlbot.org & https://github.com/RLBot/core"
);
Expand Down
1 change: 1 addition & 0 deletions RLBotCS/Server/BridgeContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ MatchStarter matchStarter
public readonly ILogger Logger = Logging.GetLogger("BridgeHandler");

public int ticksSkipped = 0;
public uint ticksSinceMapLoad = 0;
public GameState GameState = new();
public MatchStarter MatchStarter { get; } = matchStarter;
public MatchConfigurationT? MatchConfig => MatchStarter.GetMatchConfig();
Expand Down
5 changes: 5 additions & 0 deletions RLBotCS/Server/BridgeHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,10 @@ private async Task HandleServer()
float deltaTime = _context.GameState.SecondsElapsed - prevTime;
bool timeAdvanced = deltaTime > 0.001;
if (timeAdvanced)
{
_context.ticksSkipped = 0;
_context.ticksSinceMapLoad += 1;
}
else
_context.ticksSkipped++;

Expand All @@ -105,6 +108,7 @@ private async Task HandleServer()
var mapJustLoaded = MessageHandler.ReceivedMatchInfo(messageClump);
if (mapJustLoaded)
{
_context.ticksSinceMapLoad = 0;
if (_context.GameState.MatchPhase != MatchPhase.Paused)
{
// LAN matches don't set the MatchPhase to paused, which breaks Continue & Spawn
Expand Down Expand Up @@ -161,6 +165,7 @@ private async Task HandleServer()

if (
_context.MatchStarter.HasSpawnedMap
&& _context.ticksSinceMapLoad >= 2
&& _context.GameState.MatchPhase == MatchPhase.Paused
&& _context.SpawnCommandQueue.Count > 0
)
Expand Down
Loading