Commit Graph

2750 Commits

Author SHA1 Message Date
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
Aotumuri 4d3e358fbc mls (v4.7) (#2152)
## Description:

mls for v26
Version identifier within MLS: v4.7

## 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: evanpelle <evanpelle@gmail.com>
2025-10-08 13:58:36 -07:00
Vivacious Box f6839ffe99 Fix icons and add mirv to build bar (#2154)
## Description:

Fix blurry icons and add mirv to build bar
<img width="792" height="101" alt="image"
src="https://github.com/user-attachments/assets/a46c4724-c99b-4541-b56b-92ec662c8ec5"
/>

<img width="176" height="275" alt="image"
src="https://github.com/user-attachments/assets/dbcd2ed4-0f21-4065-9a52-9b16e9043270"
/>


## 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-08 13:49:54 -07:00
evanpelle 1bc0343829 Merge branch 'evan-nations' 2025-10-07 19:01:35 -07:00
FloPinguin af50e5e9c8 "Spectate" instead of "Keep playing" after loss (#2150)
## Description:

Fixes #2149

Losing a game now causes the "Keep playing" button to say "Spectate"
instead.

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

FloPinguin
2025-10-07 18:10:00 -07:00
evanpelle 0f79060f58 add openfront copyright to loading screen (#2151)
## Description:

This will make the copyright notice more clear.


<img width="369" height="242" alt="Screenshot 2025-10-07 at 6 03 44 PM"
src="https://github.com/user-attachments/assets/53925a24-bf1a-437e-84c1-3d146d598bfd"
/>

## 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-07 18:06:16 -07:00
Abdallah Bahrawi b03f9778db Fix nations break alliance too ealry bug (#2123)
Betrayal was being considered too early (inside shouldAttack), causing
alliances to break before calling attackChance.

- [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
regression is found:

abodcraft1
2025-10-07 16:04:00 -07:00
evanpelle d42fd9b5fc reduce global coverage 2025-10-07 15:20:39 -07:00
Scott Anderson e216b8a22b cleanup: Nations rarely launch nukes (#1948)
## Description:

In #1860, some unused code was left behind. Remove the unused code.

## 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
2025-10-06 15:37:04 -07:00
Scott Anderson d83a66196a bugfix: Nations rarely launch nukes (#1860)
## Description:

Simplify nation enemy selection to make nations more likely to launch
nukes.

Partially fixes #1855 by addressing a v24 regression in nation behavior.

## 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
2025-10-06 15:37:04 -07:00
Scott Anderson 8308d7f1e7 Nations send emoji when declining assistance requests (#1911)
## Description:

Nations will now send emoji when declining assistance requests.

## 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
2025-10-06 15:37:04 -07:00
Scott Anderson 81bd98c8d6 Nations send emoji when declining assistance requests (#1911)
Nations will now send emoji when declining assistance requests.

- [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

Cancel alliance requests if the recipient attacks (#1733)

Problem: attacking a player right before accepting an alliance request
is very effective since the requester can't fight back or reclaim his
territory without canceling the alliance and being penalized with the
traitor debuff.

Change:
- Attacking a player after he requested an alliance automatically
rejects the request
- No changes to existing attacks in both directions, only new attacks
affect the request

- [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 have read and accepted the CLA agreement (only required once).

regression is found:

IngloriousTom
2025-10-06 15:37:00 -07:00
Scott Anderson f0f9318852 Nations build defense posts (#1935)
## Description:

Nations build defense posts. Fixes #1854.

<img width="259" height="383" alt="image"
src="https://github.com/user-attachments/assets/aee75fd3-f52e-47d8-b47f-b192b8aaa69b"
/>

## 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
2025-10-06 14:40:46 -07:00
Scott Anderson 47edfe3e40 Nations build SAM launchers (#1931)
## Description:

Fixes #201 by adding the ability for nations to build SAM launchers.

<img width="888" height="625" alt="image"
src="https://github.com/user-attachments/assets/b07f1b4e-d022-4674-b842-bc8b4247825d"
/>

## 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
2025-10-06 14:40:08 -07:00
Scott Anderson c7f7fb0ee4 Refactor structureSpawnTileValue() (#1927)
## Description:

Move `structureSpawnTileValue()` into its own file, as
`FakeHumanExecution.ts` was getting quite large.

## 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
2025-10-06 14:36:22 -07:00
evanpelle 469a14d62a Allow attacking allies or teammates if player is disconnected (#2144)
## Description:

This will allow players to conquer land from afk teammates in team
games.

No troop loss if attacking afk teammate.

Also remove the team check in attack execution because we already do an
isFriendly check.

## 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-06 14:25:46 -07:00
Tiago Santos Da Silva fa7b7fceb3 Enable the @typescript-eslint/no-unused-vars eslint rule (#2130)
## Description:

###  Summary of Changes

This PR enables the ESLint rule **`@typescript-eslint/no-unused-vars`**
as requested in the issue and applies the necessary code adjustments
across the project.

#### 🔧 What was done:
- Activated the rule `@typescript-eslint/no-unused-vars` in the ESLint
config.
- Updated ~70 files to comply with the rule:
  - Replaced unused variables with a `_` prefix where appropriate.
- Added inline ESLint disable comments (`eslint-disable-next-line`) for
specific cases where the variable or code block seemed important for
context, readability, or future use.
- Ensured no linting errors remain related to this rule.

---

###  Clarification

Some cases were handled with inline disable comments instead of removing
the variable entirely, to avoid accidental breaking changes or loss of
intent.
If a different approach is preferred (e.g., stricter removal or
alternative handling), I’m happy to adjust the implementation
accordingly — just let me know!

---

### 🙌 Next Steps

Please review and let me know if:
- Any file should be handled differently.
- You prefer removal instead of disabling in certain areas.
- Additional rules should be enforced or reverted.

I’m available to make any follow-up improvements needed.

---

### 🎃 Hacktoberfest Note

I'm participating in **Hacktoberfest**, so if this PR is accepted,
please add the label:

`hacktoberfest-accepted`

Thank you!

#1784 

## 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-06 13:26:43 -07:00
Abdallah Bahrawi 175d492b99 Improve player panel (#2060)
## Description:

Fixes #2015
Improved the Player Panel UI for better usability and appearance.

**Screenshots**

<img width="334" height="523" alt="2"
src="https://github.com/user-attachments/assets/bd0afaac-07df-4abc-a20f-208a0783e558"
/>

<img width="337" height="523" alt="3"
src="https://github.com/user-attachments/assets/f712ad77-4546-487b-9a9c-2c535b8a45f7"
/>

**Future Plan**

Add a modal for sending gold and troops to other players from the Player
Panel.

<img width="343" height="494" alt="sending troops"
src="https://github.com/user-attachments/assets/9c9c21db-e13a-426f-93e9-b477a9db442a"
/>


## 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-06 12:45:30 -07:00
Aotumuri 715775065d Add player-stats-tree-view (#2089)
## Description:

waiting https://github.com/openfrontio/OpenFrontIO/pull/2088

This PR adds the game-list component, which displays player-stats-table
and wlr.
It provides basic functionality such as toggling details and viewing a
specific game, but does not yet include full UI integration.

In later PRs, this component will be shown together with the modal for
viewing player stats.

It should look like this:
<img width="218" height="515" alt="スクリーンショット 2025-09-26 16 23 00"
src="https://github.com/user-attachments/assets/e0aa4cc6-e3c5-4b91-9331-a1d90222ae9e"
/>

## 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: evanpelle <evanpelle@gmail.com>
2025-10-05 19:58:29 -07:00
DevelopingTom 6307a2702b Redesign target fx (#2143)
## Description:

Resize the target fx.
It's still a little too big in my opinion, but it becomes very blurry
when shrinked down.


https://github.com/user-attachments/assets/c3cda98d-ed57-4933-93b4-1cc7f1cb8e50

The UI Layer should probably not be bound to the zoom level so we can
have a sharper UI.

## 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-05 17:19:20 -07:00
Duwibi fd6b0ee062 Fix uncompacted maps (#2138)
## Description:
FIxes Yenisei and Montreal not loading. Also orders all maps in main.go
in alphabetical order.

## 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
- [ ] I have read and accepted the CLA aggreement (only required once).

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

DISCORD_USERNAME
Nikola123
v0.26.0-beta2
2025-10-04 14:07:51 -07:00