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
6 changes: 3 additions & 3 deletions RLBotCS/Conversion/FlatToCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -373,11 +373,11 @@ private static string MapInputRestriction(InputRestrictionMutator option) =>
_ => throw new ArgumentOutOfRangeException(nameof(option), option, null),
};

private static string MapScoringRule(ScoringRule option) =>
private static string MapScoringRule(ScoringRuleMutator option) =>
option switch
{
ScoringRule.Default => "",
ScoringRule.DisableGoalScoring => "DisableGoalScoring",
ScoringRuleMutator.Default => "",
ScoringRuleMutator.Disabled => "DisableGoalScoring",
_ => throw new ArgumentOutOfRangeException(nameof(option), option, null),
};

Expand Down
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.9\n"
"RLBotServer v5.beta.7.10\n"
+ $"Bridge {BridgeVersion.Version}\n"
+ "@ https://www.rlbot.org & https://github.com/RLBot/core"
);
Expand Down
13 changes: 12 additions & 1 deletion RLBotCS/Server/FlatBuffersSession.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ public readonly record struct DistributeBallPrediction(BallPredictionT BallPredi
public readonly record struct StopMatch(bool Force) : SessionMessage;

public readonly record struct UpdateRendering(RenderingStatus Status) : SessionMessage;

public readonly record struct PingResponse() : SessionMessage;
}

class FlatBuffersSession
Expand Down Expand Up @@ -306,12 +308,16 @@ await _bridge.WriteAsync(

var desiredGameState = msg.MessageAsDesiredGameState().UnPack();
await _bridge.WriteAsync(new SetGameState(desiredGameState));

break;

case InterfaceMessage.RenderingStatus:
var renderingStatus = msg.MessageAsRenderingStatus();
await _rlbotServer.WriteAsync(new UpdateRendering(renderingStatus));
break;

case InterfaceMessage.PingRequest:
_incomingMessages.Writer.TryWrite(new SessionMessage.PingResponse());
break;
}

return true;
Expand Down Expand Up @@ -427,6 +433,11 @@ private async Task HandleInternalMessages()
}
}
break;
case SessionMessage.PingResponse m:
SendPayloadToClient(
CoreMessageUnion.FromPingResponse(new PingResponseT())
);
break;
}
}

Expand Down