mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-06-25 19:24:36 +00:00
4ee3cbc255
## Description: This PR addresses issue #2302: where there is no obvious information about the self-player's team during the spawn phase of the game. Currently, during TEAM games (where there is a set number of teams defined), the self player's spawn highlight color is white, while all other players are shown with a team-based spawn highlight color. This makes it difficult to discern who is a teammate, especially since the current live version (v0.26.7) uses green/yellow for other players to depict teammate/other team, respectively. Technically, the same is true for Duos, Trios, and Quads games, although this has been addressed separately with PR #2298 by reverting to green/yellow for teammate/other team players. This PR changes the color of the self player's breathing spawn highlight ring to match their assigned team color (with `alpha=0.5` for transparency). The breathing ring is semi transparent on top of the existing white static semi-transparent ring, giving the breathing ring a **tint** of the team color instead of the exact team color. This allows a player to immediately identify their assigned team and maintains overall consistency with FFA, Duos, Trios, and Quads game modes. See below for example implementation. In this screenshot, the self player is on the red team as shown by the red tint to the breathing spawn highlight ring. The screenshot also shows some of the static white semi-transparent ring around the spawn location. The self player's teammate is to the top left of the image with a solid red spawn highlight. The non-player (nation) opponent on the blue team is shown to the bottom left. In online games, nations are not present in team games. In single player or private lobby games they are shown as here, without a spawn color highlight and only a territory color. <img width="402" height="292" alt="Team Spawn Color Tint" src="https://github.com/user-attachments/assets/5696a408-a633-4ec8-bf93-c8afa8e2e121" /> ## Please complete the following: - [x] I have added screenshots for all UI updates - [x] I process any text displayed to the user through translateText() and I've added it to the en.json file - [x] I have added relevant tests to the test directory - [x] I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced ## Please put your Discord username so you can be contacted if a bug or regression is found: GlacialDrift