Merged
Conversation
There was a problem hiding this comment.
Pull Request Overview
Refactors how union packets and event details are represented and accessed, migrating to a TryGet API, while updating multi-targeting, tests, and benchmarks.
- Replace public packet properties with private fields, constructors, and
TryGet*methods inUnionPacketandEventDetails. - Update README examples, project files, tests, and benchmarks to reflect the new API and add net9.0 support.
- Simplify
IByteWritable.WriteBytesimplementations and configure tests to include internal fields.
Reviewed Changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| README.md | Updated usage examples to the TryGet<PacketName> pattern |
| F1Game.UDP/Packets/UnionPacket.cs | Refactored UnionPacket to use private fields, constructors, TryGet methods, and updated byte writing |
| F1Game.UDP/Packets/EventDataPacket.cs | Simplified WriteBytes to delegate to EventDetails |
| F1Game.UDP/Events/EventDetails.cs | Implemented IByteWritable, added constructors, TryGet* methods, and streamlined implicit operators |
| F1Game.UDP/F1Game.UDP.csproj | Added net9.0 to <TargetFrameworks> |
| F1Game.UDP.Tests/PacketReaderFixture.cs | Configured equivalency to include internal fields |
| F1Game.UDP.Tests/F1Game.UDP.Tests.csproj | Added net9.0 to test project <TargetFrameworks> |
| F1Game.UDP.Benchamrks/ThirdPartyComparisonBenchmark.cs | Switched to TryGet* in benchmarks and added NET9 job |
| F1Game.UDP.Benchamrks/Program.cs | Added NET9 benchmark job |
| F1Game.UDP.Benchamrks/F1Game.UDP.Benchmarks.csproj | Added net9.0 multi-targeting and LangVersion |
| .editorconfig | Added csharp_prefer_system_threading_lock rule and tab indent style |
Comments suppressed due to low confidence (1)
F1Game.UDP.Benchamrks/ThirdPartyComparisonBenchmark.cs:1
- The folder and project name
Benchamrksappears to be misspelled; consider renaming it toBenchmarksfor consistency.
F1Game.UDP.Benchamrks
4d6b2a7 to
1bf53fd
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.