Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't display unknown diplomatic relations as war #2061

Merged

Conversation

lmoureaux
Copy link
Contributor

The diplomatic status between two nations the current player has no contact with is usually not known by the client. The server sends "war" in this case (it should arguably not send anything at all). It also sets the NI_DIPLOMACY bit in client.visible to false to tell the client that this information is not available. However, the client ignores this and just displays "war".

Make the client ignore diplomatic relations between two players when the NI_DIPLOMACY bit is false for both players -- that is, when no information is available. This prevents the client from displaying invalid data.

Discovered during LeagueB2.
Backport candidate (I confirmed that stable already has the NationalIntelligence feature that this patch requires)

The diplomatic status between two nations the current player has no contact
with is usually not known by the client. The server sends "war" in this case
(it should arguably not send anything at all). It also sets the NI_DIPLOMACY
bit in client.visible to false to tell the client that this information is not
available. However, the client ignores this and just displays "war".

Make the client ignore diplomatic relations between two players when the
NI_DIPLOMACY bit is false for both players -- that is, when no information is
available. This prevents the client from displaying invalid data.

Discovered during LeagueB2.
@lmoureaux lmoureaux requested a review from jwrober November 26, 2023 22:39
Copy link
Collaborator

@jwrober jwrober left a comment

Choose a reason for hiding this comment

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

LGTM

@lmoureaux lmoureaux merged commit 7aedb97 into longturn:master Nov 27, 2023
19 checks passed
@lmoureaux lmoureaux deleted the bugfix/nations-unknown-dipl-rel branch November 27, 2023 23:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants