Skip to content

Conversation

@helmutbuhler
Copy link

A different magic value for network messages ensures that VS22 build players (for example GO) won't interfere with retail compatible build players.

@helmutbuhler helmutbuhler added Enhancement Is new feature or request Network Anything related to network, servers Fix Is fixing something, but is not user facing labels Oct 26, 2025
xezon
xezon previously approved these changes Oct 27, 2025
Copy link

@xezon xezon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

F00F

Needs to be replicated in Generals.

@xezon xezon added Gen Relates to Generals ZH Relates to Zero Hour Approved Pull Request was approved labels Oct 27, 2025
@helmutbuhler
Copy link
Author

Done

// Original retail value is used for builds with VC6
static const UnsignedShort GENERALS_MAGIC_NUMBER = 0xF00D;
#else
static const UnsignedShort GENERALS_MAGIC_NUMBER = 0xF00D+1;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thinking about this again, this means new clients will not see retail client, right? That means some players cannot see a group of other players, which may or may not be desirable.

Ideally, all clients would be able to see all other client rooms in the lobby, but not be able to join them if incompatible. There are perhaps tricks we can do to prevent retail clients messing with rooms of new clients. Preventing new clients from joining retail client rooms should be possible.

@xezon xezon added OngoingDiscussion Requires further discussion and removed Approved Pull Request was approved labels Nov 5, 2025
@xezon xezon dismissed their stale review November 5, 2025 17:47

ongoing discussion

};

// Magic number for identifying a Generals packet.
#if defined(_MSC_VER) && _MSC_VER < 1300
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

&& RETAIL_COMPATIBLE_CRC maybe too?

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

Labels

Enhancement Is new feature or request Fix Is fixing something, but is not user facing Gen Relates to Generals Network Anything related to network, servers OngoingDiscussion Requires further discussion ZH Relates to Zero Hour

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants