Skip to content

Comments

766 Issue enforce game version compatibility to prevent matchmaking across different versions#774

Open
CapoMK25 wants to merge 4 commits intodevfrom
766-issue-enforce-game-version-compatibility-to-prevent-matchmaking-across-different-versions
Open

766 Issue enforce game version compatibility to prevent matchmaking across different versions#774
CapoMK25 wants to merge 4 commits intodevfrom
766-issue-enforce-game-version-compatibility-to-prevent-matchmaking-across-different-versions

Conversation

@CapoMK25
Copy link
Collaborator

@CapoMK25 CapoMK25 commented Feb 9, 2026

Brief description

This PR introduces client_version tracking for online players. This field allows the system to identify the game build version during the "ping" process, ensuring better matchmaking isolation and helping to prevent desyncs between incompatible client versions.

This change was requested from the lead of the project to ensure that incompatible versions wouldn't be able to match with each other.
The data is persisted in the Redis cache and is available for filtering when retrieving the list of online players.

Change list

  • Domain Model Update: Added client_version to the OnlinePlayer domain class and applied @Expose() decorators to ensure property visibility during serialization.

DTO Validation: Updated the AddOnlinePlayer payload class with @IsString() and @IsOptional() decorators to validate incoming client version data from the /ping endpoint.

Service Logic:

Modified addPlayerOnline to extract client_version from the request and include it in the Redis payload.

Updated getOnlinePlayers to support optional filtering by client_version.

Infrastructure & Cache

Redis Payload: Updated the JSON schema stored in Redis to include the new version string.
output

Test & Verification

Manual Verification: Confirmed via server logs that client_version is correctly received by the service and retrieved from the cache.

Postman Testing: Verified that sending client_version in a POST request results in the data being successfully processed by the backend.

@CapoMK25
Copy link
Collaborator Author

Jenkins choked yesterday for some odd reason and took ages to finish. I re-ran it today just in case and now the CI is all green and ready for review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Backlog

Development

Successfully merging this pull request may close these issues.

1 participant