Skip to content

Conversation

@kimden
Copy link
Owner

@kimden kimden commented Apr 13, 2025

Successful compilation doesn't mean working code

Agreement

By creating a pull request in stk-code, you hereby agree to dual-license your contribution as
GNU General Public License version 3 or any later version and
Mozilla Public License version 2 or any later version.

This includes your previous contribution(s) under the same name of contributor.

Keep the above statement in the pull request comment for agreement.

@kimden kimden force-pushed the disgusting-protocol-cleanup branch from 27944dd to 1348ff7 Compare April 13, 2025 13:15
@kimden kimden added T: improvement New feature or request P1: critical Urgent or very important T: Great Projects Bright future that probably won't happen C: Performance / Refactoring Making code running or being better C: Network Protocol Low level interaction labels Apr 13, 2025
@kimden kimden force-pushed the disgusting-protocol-cleanup branch from 7937e28 to 02a1972 Compare April 20, 2025 14:28
@kimden kimden force-pushed the disgusting-protocol-cleanup branch from 418d757 to c1f6fba Compare June 7, 2025 00:09
kimden added 21 commits July 6, 2025 15:13
(due to pretty much everything being interconnected, I'll continue later if I can)
[skip ci]
[skip ci] because the road to successful compilation is very long
[skip ci, not able to build yet]
[skip ci] It's getting slightly annoying tho with all those 'arbitrary' options. I should reconsider some syntax things
Had also to move some things in packets and network string, they also accidentally included each other
The next step is making sure types in packets are differentiated by their encoding/decoding method
Not everything of course is implemented, bugs exist too, in particular, ownerless start button doesn't work after racing
It broke server joining for now
@kimden kimden force-pushed the disgusting-protocol-cleanup branch from 54eb295 to f89d8fa Compare July 6, 2025 11:20
- Move sendString, sendPacket to Comm::
- Keep sendPacketPtr, sendNetstring to STKHost
- Leave a few sendNetstring-s in Comm:: as deprecated.

[skip ci]
@kimden kimden force-pushed the disgusting-protocol-cleanup branch from 056cb3d to 7196df9 Compare July 8, 2025 21:39
kimden added 2 commits July 10, 2025 03:58
[skip ci]

You look at GameProtocol's network packet formation. It is confusing. The order of things is confusing.
You look at places where it's decoded. They are confusing.
You look at places where the decoded packet is applied. They are of a base class which means you'll still have to work on them, but for now, you can do nothing without diving deep into them.
You look at the rest of code, and you see a map from network packet encoded as array of uint8_t encoded as string.
I would like to express my profound gratitude to creators of this code.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C: Network Protocol Low level interaction C: Performance / Refactoring Making code running or being better P1: critical Urgent or very important T: Great Projects Bright future that probably won't happen T: improvement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants