Commit Graph

2570 Commits

Author SHA1 Message Date
Vivacious Box dddf54be0b Add deletion duration and indicators (#2216)
## Description:

Adds a timer before self deleting units
Adds a loading bar under deleting units
Adds a timer in radial menu for clarity purposes


![deletecd](https://github.com/user-attachments/assets/613bf742-ef90-42b5-a258-b928daae6aaa)

## 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:

Mr.Box

---------

Co-authored-by: Evan <evanpelle@gmail.com>
2025-10-21 10:07:14 -07:00
MaxHT0x 19597a37d9 Fix slow radial menu animation for mobile players (#2201) (#2248)
## Description:

Closes #2201

Remove CSS transition from SVG element that was causing the radial menu
to animate from its previous position to the new clicked position. This
was creating delays of up to 2 seconds for mobile players, making the
game unplayable on mobile devices.

The viewport clamping functionality (from PR #1817) is preserved - the
menu now appears instantly at the correct clamped position instead of
animating to it.

I wasn't sure if this should only apply for mobile players, but making
it so sounded too much trouble for what it's worth so its removed
entirely

## 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:

stackk.
2025-10-21 09:49:33 -07:00
Duwibi d5174d02ec Readd Translation Discord link (#2255)
## Description:
Updated translation instructions and added new Discord link.

## Please complete the following:

- [ ] I have added screenshots for all UI updates
- [ ] I process any text displayed to the user through translateText()
and I've added it to the en.json file
- [ ] I have added relevant tests to the test directory
- [ ] 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:

DISCORD_USERNAME
Nikola123

---------

Co-authored-by: Evan <evanpelle@gmail.com>
Co-authored-by: Loymdayddaud <145969603+TheGiraffe3@users.noreply.github.com>
2025-10-21 09:48:49 -07:00
evanpelle 73bf583452 update section 7 attribution terms 2025-10-18 17:26:30 -07:00
Vivacious Box f161c94ff4 Max timer (#1289)
## Description:

Adds a max timer setting
The timer starts at max timer and goes down, becoming red if reaching <
1 min
The player with the biggest territory wins at the end of the timer


![image](https://github.com/user-attachments/assets/888099fc-95ae-4303-8c80-c850e58d36e2)

## 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
- [x] I understand that submitting code with bugs that could have been
caught through manual testing blocks releases and new features for all
contributors

## Please put your Discord username so you can be contacted if a bug or
regression is found:

Vivacious Box

---------

Co-authored-by: Loymdayddaud <145969603+TheGiraffe3@users.noreply.github.com>
2025-10-17 17:09:10 -07:00
Aotumuri 75ca2fb349 Reduce redundant toggle strings to stay within Crowdin limits (#2219)
## Description:

Purpose: to reduce redundant strings and avoid exceeding Crowdin’s text
limit.

- Replaced _enabled/_disabled text with shared ..._desc in
SettingsModal.ts.

<img width="432" height="645" alt="スクリーンショット 2025-10-17 21 38 47"
src="https://github.com/user-attachments/assets/10942de4-1b2c-4df4-8811-95190463a2ab"
/>


## 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:

Aotumuri

Co-authored-by: Evan <evanpelle@gmail.com>
2025-10-17 14:39:33 -07:00
VariableVince 94a30bc4c7 Add Reddit link to footer on homepage (#2223)
## Description:

Add Reddit link to the footer on the homepage. Left of _Join the
Discord!_ and to the right of _Wiki_.

Before:
<img width="1917" height="342" alt="image"
src="https://github.com/user-attachments/assets/d5a105eb-d284-45ab-af6b-431967d293bb"
/>

After:
<img width="1915" height="372" alt="image"
src="https://github.com/user-attachments/assets/e4bb505b-ce5b-4880-adb2-bb66cd4bdc3a"
/>


## 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:

tryout33
2025-10-17 14:24:29 -07:00
icslucas 141c431a93 Enzo video for tutorial (#2208)
## Description:
enzo video
Describe the PR.
enzo video for tutorial

## 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:
Lucas
2025-10-17 02:57:14 +00:00
evanpelle 5540eff24c Merge branch 'v26' 2025-10-14 20:24:15 -07:00
evanpelle 349e7acb61 bugfix: have Privilege support flags v0.26.4 2025-10-14 20:07:05 -07:00
evanpelle eea8db7a06 delete warship when player is afk 2025-10-14 19:51:58 -07:00
evanpelle 9ab35a0436 bugfix: don't use bigint for zod schema as it causes json parsing issues v0.26.3 2025-10-14 19:05:53 -07:00
evanpelle 5579fcf91b update win_modal territory pattern to say go ad free v0.26.2 2025-10-14 18:01:16 -07:00
Evan 090b0756b7 Allow donation in team games. (#2198)
## Description:

Was a bug disabling donation in public team games.

## 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:

evan
v0.26.1
2025-10-14 16:10:32 -07:00
Hiphex fee2f822ed Fix spelling typos and improve code quality (#2186)
## Description:
  This PR fixes several bugs and improves code quality:

- Fix spelling typos: "recieved" → "received" in Transport.ts and
GameServer.ts
  - Fix comment typo: "isn'te" → "isn't" in TerrainLayer.ts
- Improve WebSocket cleanup in Transport.ts leaveGame() by replacing
empty onclose handler with proper
   killExistingSocket() call
- Add console.warn for image decode failures in StructureLayer.ts
instead of silent catch
  - Remove commented dead code in DevConfig.ts

  ## Testing
All 288 tests pass. Development build completes successfully. No
breaking changes.

  ## Files Changed
  - src/client/Transport.ts
  - src/server/GameServer.ts
  - src/client/graphics/layers/TerrainLayer.ts
  - src/client/graphics/layers/StructureLayer.ts
  - src/core/configuration/DevConfig.ts

## Checklist:
- [x] I have added screenshots for all UI updates (N/A - no UI changes)
- [x] I process any text displayed to the user through translateText()
and I've added it to the en.json file (N/A - no user-facing text)
- [x] I have added relevant tests to the test directory (All 288
existing tests pass - no new tests needed for typo fixes)
- [x] I confirm I have thoroughly tested these changes and take full
responsibility for any bugs introduced

  Discord: hiphex_33496

Hiphex

Co-authored-by: Claude <noreply@anthropic.com>
2025-10-14 22:07:49 +00:00
Evan bce27f1a6b don't show ads if skin has been purchased, fixed ads not getting removed sometimes (#2196)
## Description:

Now checks if player has any "pattern" flares and does not show ads.
Also set visible=false when hiding ads, sometimes the ads were not
getting destroyed properly.

## 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:

evan
v0.26.0
2025-10-14 13:55:30 -07:00
evanpelle 5f6b85ebfc Merge branch 'v26' 2025-10-14 12:03:43 -07:00
evanpelle 810b12b7ff Merge branch 'v25' into v26 2025-10-14 12:02:44 -07:00
VariableVince 69fc14f1fd Fix user having to click 3-4x times before building is deleted (#2195)
## Description:

There is a 5 second cooldown between building deletions (as was proposed
here:
https://github.com/openfrontio/OpenFrontIO/pull/1609#issuecomment-3146188728).

But this cooldown is only checked when in DeleteUnitExecution from
canDeleteUnit in PlayerImpl.
The delete button in RadialMenuElements always gets True back from
canDeleteUnit in GameView.

This results in a user seeing an enabled Delete button after just
deleting another building. And being able to click it, but no deletion
would happen. So they have to click 3-4 times before it 'works'.

Fix: also apply the 5s cooldown when deciding to disable the button. 

In the fix in canDeleteUnit in GameView, added +1 to the current game
tick. So the Delete button is enabled 1 tick before DeleteUnitExecution
would get True back from canDeleteUnit in PlayerImpl. Between seeing and
clicking the button is probably 1 tick anyway, and sometimes also after
clicking it and the execution it takes another tick so this is safe.
Also tested the other way around: after deletion the button should
immediately not be visible, while it can take 2 ticks before GameView
gets lastDeleteUnitTick back from PlayerImpl. But since the Radial menu
is closed after clicking the button, i couldn't open it fast enough
again to still see the button enabled (ie. it was always already neatly
disabled). And if someone with an auto-clicker were to be able to click
it still, their attempt would still be blocked by the cooldown check in
DeleteUnitExecution.

BEFORE:

https://github.com/user-attachments/assets/17242c39-982e-47c6-89f2-6fe22a296c7d

AFTER:

https://github.com/user-attachments/assets/dfe20111-3313-4ad2-95a9-0152c0270c08

## 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:

tryout33

---------

Co-authored-by: evanpelle <evanpelle@gmail.com>
v0.26.0-beta4
2025-10-14 11:18:50 -07:00
VariableVince 2f67c45a17 Cleanup redundant code win tad performance back (#2194)
## Description:

Cleanup code & small perf improvement

Gave it v26 milestone because it gives a little perf bump at no cost,
all the removed code isn't used anywhere so can be safely deleted.
Triple checked.

- Remove 'setFocusedPlayer' and 'checkTileUnderCursor' (not to be
confused by still in use 'getTileUnderCursor') from ClientGameRunner,
'_focusedPlayer' and 'setFocusedPlayer' (not to be confused with
still-in-use 'focusedPlayer') from GameView, and 'setFocusedPlayer' from
TransformHander.
These are remnants of PR #304, the first one that added highlighting
territory. The remants are still ran for every mouse-move, costing some
performance for no reason. _focusedPlayer is never used anywhere
anymore, only calculated and set.

It was later adapted from #387. But ultimately almost completely
disabled because it was too performance-costly, from commits 15c2cc1 and
then ec895af.

The thing that remained was permanent highlight of the player's own
border. For that, function 'focusedPlayer' in GameView is still used by
'drawFocusedPlayerHighlight' in TerritoryLayer. But it simply returns
myPlayer instead of the obsolete _focusedPlayer that it returned
earlier. Function 'focusedPlayer' still had the annotation "// TODO:
renable when performance issues are fixed." which i removed. Because
another PR for highlighting other's territory already followed it up
with its own functions, so chances of needing to change 'focusedPlayer'
back are very slim.

Later PR #1320 introduced a new attempt for highlighting territory in
the alternate view. It used its own equivalent functions in
TerritoryLayer for MouseOver and updateHighlightedTerritory (the latter
being the equivalent of the old checkTileUnderCursor in
ClientGameRunner). That was also disabled in part due to perfomance
cost, and now only shows border color changes. All this to say: the
remnants of PR 320 and 387 have long been redundant.

- Main: removed uncommented chatModal code, which was never used and
leftover from tests during development probably.

- PlayerActionHandler: removed handleQuickChat and the
sendQuickChatEvent import it needed. It was added in PR Multi-level
radial menu #1018. But the new Radial menu in the meantime moved to
using ChatIntegration.ts to send the chat event, or from there opened
the original Chat Modal which then sent the chat event. Later on, chat
was even removed from the Radial menu. 'handleQuickChat' is used nowhere
anymore and isn't needed. This is maybe also the case for
ChatIntegration, but i didn't remove it because it may still be enabled
again in the future for UI changes or something.

- OptionsMenu: removed, also from index.html (options-menu). This menu
has been succeeded by GameRightSidebar (game-right-sidebar for
index.html) for awhile now.

## 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:

tryout33
2025-10-14 11:12:37 -07:00
Michal Martínek 522413678a Enabled the @typescript-eslint/no-unused-expressions eslint rule (#2014)
## Description:

- Fixes #1790
- Fixed the codebase:
- expressions short-circuiting with `&&` changed to proper `if`
statements
  - `A instanceof B;` expressions now emit warnings

## 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:
michal7952

---------

Co-authored-by: Evan <evanpelle@gmail.com>
2025-10-14 11:10:52 -07:00
Evan 2c58947839 update license - clarify attribution requirement (#2192)
## Description:

Clarify and add additional requirements to attribution.

## 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:

evan
2025-10-14 09:42:36 -07:00
Evan b58d140f94 fix encirclement issues (#2191)
## Description:

Players with no ongoing attacks were ignored during cluster calculations
in
https://github.com/openfrontio/OpenFrontIO/commit/3680d9cc1663a22f0e174d2c2de806c0ee78b923

This PR has it fallback to neighbor with largest border if no ongoing
attacks

## 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:

evan
v0.26-beta4
2025-10-13 19:54:05 -07:00
evanpelle f016c3ee9d don't show ads if in iframe v0.25.23 2025-10-13 19:03:16 -07:00
evanpelle e7497bfb76 Revert "Slider UI change (#2148)"
This reverts commit 972697a5ae.
2025-10-13 17:53:13 -07:00
Evan d55c145298 publift homepage ads (#2160)
## Description:

Put ads on the left and right gutters

## 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:

evan
v0.25.22
2025-10-13 17:32:28 -07:00
Baeck Dong Jae 972697a5ae Slider UI change (#2148)
## Description:

1. adds feature so when making single player server, bots amount can be
determined by slider and manual
1-1.
[video](https://github.com/user-attachments/assets/23186592-2330-478b-8f73-313ca073803b)

## 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:

jack_45183

---------

Co-authored-by: evanpelle <evanpelle@gmail.com>
2025-10-13 11:37:17 -07:00
VariableVince 11ae047e33 Fix Boat hotkey (B) behaviour (#2179)
## Description:

Fixes Issue #2177, land border required to send boat. And fixes boat not
being sent for longer distances.

- Boat Hotkey (B) (PR #1060) was implemented seemingly with a wrong
assumption. Namely that it should do the same checks as the AUTO BOAT
functionality (PR #540) before sending a transport ship. But it should
have done the same checks as when sending a MANUAL transport ship, as if
the Radial Menu was used. Basically the same checks as in
RadialMenuElements line 508-532.

Because of this it wrongly required:
- there to be no land border with the other player 
(while boat from radial menu gets sent without bothering about this)
- the tile clicked to be a Land tile 
(only makes sense in the context of auto-boating where user clicks to
attack an enemy on their land, and only if there's no border will it
then send a boat to that land if possible)
- the distance to be short
(since auto-boat was mainly meant to automatically cross rivers)

Fixed this by removing canAttack check (for the unwanted land border
requirement) and splitting up the auto boat and the manual boat checks.

- canBoatAttack: moved out the parts which where only meant for
auto-boating
- shouldBoat: moved in the parts from canBoatAttack that where only
meant for auto-boating. Renamed it to canAutoBoat for better
discernability. Gave it early returns for tad better performance and
consolidated returns in the bottom, while keeping the same
functionality.

## Please complete the following:

- [ ] I have added screenshots for all UI updates
- [ ] I process any text displayed to the user through translateText()
and I've added it to the en.json file
- [ ] 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:

tryout33
2025-10-13 11:14:03 -07:00
evanpelle 9201fad9bc update readme, remove duplicate licensing section (#2184)
## Description:

Make links to license files more clear and remove duplicate license
section.
Change "registered trademark" => "trademark" because registration is in
progress.

## 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:

evan
2025-10-13 10:15:33 -07:00
evanpelle 1ee3cf7ce3 add attribution requirement when forking (#2182)
## Description:

Describe the PR.

## 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:

evan
2025-10-12 19:19:49 -07:00
evanpelle 136cfa1316 improve nation ai (#2172)
## Description:

1. Create forceSendAttack function so nations expand faster at the start
(their reserve troop ratio was too low, causing them to skip the first
attack
2. modify the perceived cost modifier to reduce the number of defense
posts built.
3. Updated how random land is selected to avoid player.tiles() since
that can be millions of entries.
4. Improve performance of valueFunction by using closestTile and
reducing the number of tiles checked.
5. Nations now launch hydros if they have enough gold.
6. used boundBox instead of bfs because doing a large bfs for h-bombs
can get expensive.
7. Modified perceived multiplayer to remove cap and scale super-linearly
to discourage nations from spamming too many building. Instead they are
more likely to spend that money on nukes.

## 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:

evan
v0.26.0-beta3
2025-10-11 19:35:11 -07:00
VariableVince 730d492475 Fix owned % in Teams stats (#2176)
## Description:

In Teams games, the Leaderboard for individual players shows a different
Owned % than the Team stats next to it. This is because Leaderboard
correctly takes fallout/nuked territory into account (lines 99 and 113).
But Team stats doesn't.

It's only visual because the win condition for 95% of the land is also
already calculated correctly in WinCheckCondition (lines 78-80).

There is still a difference where Leaderbord uses toFixed(1) and
TeamStats does toPrecision(2). Didn't touch that because i don't know
the reason for it.

BEFORE:
<img width="699" height="206" alt="Team stats owned not taking fallout
into consideration"
src="https://github.com/user-attachments/assets/3bd03671-e32a-4c7a-b097-cfd8201c4299"
/>

AFTER:
<img width="892" height="453" alt="image"
src="https://github.com/user-attachments/assets/10c3eae8-8292-404f-83d5-820d10279367"
/>

## 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
- [ ] 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:

tryout33
2025-10-11 13:40:07 -07:00
Vivacious Box 843aa11c84 Fix the ghost unit turning green when hovering an ennemy structure (#2175)
## Description:

Fix the ghost unit turning green when hovering an ennemy structure

## 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:

DISCORD_USERNAME
2025-10-11 10:05:23 -07:00
evanpelle b9a4add1ca Revert "Added trackpad support for moving maps (#1717)"
This reverts commit 8746df69fd.
2025-10-10 17:54:29 -07:00
evanpelle d59b73d6b9 Revert "Fix: Rework wheel and touch handling for pan and zoom (#1956)"
This reverts commit 584acea7ed.
2025-10-10 17:54:13 -07:00
Angel Uriot fa6e4fce00 Remove confusing characters from game IDs (#2171)
## Description:

I have often encountered the problem of characters that look alike when
typing a private game code, mainly `l` / `I`, and `O` / `0`.

In this PR, I therefore propose removing these 4 characters from ID
generation.

The number of possible combinations goes from $$2.2\times10^{14}$$ to
$$1.3\times10^{14}$$, which is still the same order of magnitude.

## Please complete the following:

- [ ] ~~I have added screenshots for all UI updates~~
- [ ] ~~I process any text displayed to the user through translateText()
and I've added it to the en.json file~~
- [ ] ~~I have added relevant tests to the test directory~~
- [ ] ~~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:

`@dimension`
2025-10-10 11:14:04 -07:00
Loymdayddaud c9c29308d7 update stale action (#2168)
## Description:

Updates the stale action to:

1. Do nothing with issues, since issues should generally not stale
2. Close PRs and add the Orphaned label to them, along with a comment
about being unmaintained
3. Add a "will not stale" label for PRs we don't want to be closed
4. Removes the start-date because there's really no reason for it

## 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:

loymdayddaud
2025-10-09 22:07:23 -07:00
evanpelle 584fa9fb5d add support for custom colors (#2103)
## Description:

Added a colors tab in territory patterns modal so players can select
their color.

Refactored the PrivilegeChecker, removed custom flag checks since we no
longer support custom flags.

<img width="479" height="345" alt="Screenshot 2025-09-27 at 5 01 17 PM"
src="https://github.com/user-attachments/assets/ad96da65-f0eb-4731-a861-e6e5fcb4566a"
/>
## 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:

evan
2025-10-09 20:47:20 -07:00
evanpelle 2521466191 Merge branch 'v25' 2025-10-09 19:54:35 -07:00
DevelopingTom 4f73548a4e Use larger responsive classes (#2167)
## Description:

Issue:
With low resolution screens, or simply by resizing the window, the build
menu can be drawn above the event logs:
<img width="513" height="180" alt="image"
src="https://github.com/user-attachments/assets/01c62002-467d-47c0-b3a1-b46446d4dbc9"
/>

Changes:
- use larger responsive Tailwind classes:


https://github.com/user-attachments/assets/e583b70e-235a-4f5b-b10d-d032ac621984


## 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:

IngloriousTom

Co-authored-by: evanpelle <evanpelle@gmail.com>
2025-10-09 19:26:53 -07:00
Jeff 649e4d2ed7 fix(PlayerExecution): remove alarming DefensePost destruction messages on capture (#2163)
## Description:

Patches issue flagged from
https://github.com/openfrontio/OpenFrontIO/pull/1957#issuecomment-3386398998.

Right now for every single defense post capture, attackers receive two
messages:
- "Your Defense Post was destroyed" and "Captured Defense Post from ..."

By downgrading before captures, behavior will now be:
- defender receives "Your Defense Post was destroyed"
- attacker receives no message unless capturing a lv2+ defense post
(downgraded to lv 1), in which case they receive "Captured Defense Post
from ..."

## 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:

`seekerreturns`

---------

Co-authored-by: evanpelle <evanpelle@gmail.com>
2025-10-10 02:21:05 +00:00
evanpelle cc49dc986e reduce coverage threshold 2025-10-09 18:12:10 -07:00
Vivacious Box a8002a038c Transparent railroads (#2153)
## Description:

Make the railroads fade before disappearing

## 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:

Mr. Box
2025-10-09 15:31:22 -07:00
DevelopingTom fc38fed972 Fix target FX on retreating units (#2166)
## Description:

Retreating naval invasions spams the target FX each frames.
Changes: filter out retreating invasions.

## 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:

IngloriousTom
2025-10-09 14:44:17 -07:00
Abdallah Bahrawi 0076996dce Implement send resources modal (#2146)
## Description:
Fixes https://github.com/openfrontio/OpenFrontIO/issues/2015
Implemented a new interactive modal component for sending troops/gold
between players, replacing the previous automatic troop donation system.

Screenshots
<img width="388" height="569" alt="s1"
src="https://github.com/user-attachments/assets/b5b5cfce-972e-474c-848a-4ea0dc7dde8f"
/>

<img width="383" height="534" alt="s2"
src="https://github.com/user-attachments/assets/4c467fa2-7631-4e7b-ab17-898778b08ea6"
/>

<img width="377" height="548" alt="s3"
src="https://github.com/user-attachments/assets/9359ee06-18af-48ea-a47c-586198e26f57"
/>

## 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:

abodcraft1

---------

Co-authored-by: evanpelle <evanpelle@gmail.com>
2025-10-09 13:19:05 -07:00
Loymdayddaud d070c5810c Increase the frequency of teams games (#1809)
## Description:

Updates the frequency of teams games to fix #1808.

## 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:

loymdayddaud

Co-authored-by: TheGiraffe3 <TheGiraffe3@users.noreply.github.com>
2025-10-09 19:56:51 +00:00
Britton Fischer 3680d9cc16 fix: allies cannot annex your clusters (#2158)
## Description:

Fixes #1685
Continuation from #1924, which was auto-closed after the upstream repo
force-pushed main and I synced my fork.

This change ensures that allies are excluded from the `getMode()` call
made by `getCapturingPlayer()` inside `removeCluster()`.

- Previously, friendly neighbors were treated as candidates for
capturing, leading to incorrect annexations in certain edge cases.
- Added a small efficiency improvement by filtering out non-player and
friendly neighbors up front to reduce total computations down-the-line.
- Important: we can’t simply check if the `getMode(neighborsIDs)` result
is a friendly. Doing so would cause the territory to go to nobody until
the user is attacked. I believe the expected behavior is the largest
neighboring enemy should take it automatically.

Here's an example of the new behavior in an extreme edge case:
<img width="622" height="422" alt="Screenshot 2025-08-24 at 4 56 46 PM"
src="https://github.com/user-attachments/assets/c5dd9c0d-0a3c-4657-8154-e114fa920689"
/>

## 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:

nottirb
2025-10-08 18:28:26 -07:00
Jeff 187ef1f2dd feat(PlayerExecution): downgrade defense posts on capture (#1957)
## Description:

Closes https://github.com/openfrontio/OpenFrontIO/issues/1619.

On capture, defense posts will be downgraded.

On the live version this means defense posts will be destroyed, as
defense posts can only be level 1.

Misc. changes:
- added `decreaserLevel` helper
- cleaned up if/else in tick unit loop for clarity to avoid yet another
nested layer

Continuation of the stale PR,
https://github.com/openfrontio/OpenFrontIO/pull/1622.

## 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:

Discord username: `seekerreturns`
2025-10-08 17:31:56 -07:00
evanpelle e895e53a1e fix spawn highlighting bug & improve highlight ring (#2157)
## Description:

The PR that added a highlight ring, broke highlights for other player
spawns. This PR fixes that, and makes the highlight ring more visible.

## 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:

evan
2025-10-08 16:40:53 -07:00
Vivacious Box 020b0de875 Fix forgotten mirv cursor (#2156)
## Description:

Forgot to show cross cursor for mirv

## 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:

Mr.Box
2025-10-08 16:40:39 -07:00