Skip to content

Traitor debuff triggers if alliance is accepted while an attack click is in progress (race condition) #1866

@abdallahbahrawi1

Description

@abdallahbahrawi1

Describe the bug
Sometimes the 50% “Traitor” debuff is applied even though an alliance has just been accepted. This happens when one player is mid-attack and clicks at the exact moment the alliance request is accepted, causing the game to treat the attack as a betrayal.

To Reproduce

1- Player A and Player B are not allied.
2- Player A begins an attack on Player B (click to attack).
3 - While Player A is still in the “attack” input (Not sure if the player must be attacking to trigger this bug), an alliance request between A and B gets accepted (either direction).
4 - Player A sends attacks right after the alliance acceptance.

Actual behavior
Player A immediately gets the 50% Traitor debuff, even though the alliance was just accepted.

Expected behavior
The attack should be canceled, and no Traitor debuff should be applied.

Screenshots

https://drive.google.com/file/d/1YuYET07blnP8N5qPud25eRWWyg0_HI-B/view?usp=sharing

If accepted, please assign this issue to @AbdallahBahrawi (me). I’m happy to work on a fix.

Metadata

Metadata

Labels

Type

Projects

Status

Triage

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions