Commit Graph

24486 Commits

Author SHA1 Message Date
Cayleb-Ordo 90d276b0dc Make windows batch-scripts independent of calling directory
Change dir to batch-script location as first action. This
allows to run the script from outside the directory its stored.
2025-01-05 19:38:37 +01:00
phosit 21eddf0d39 Silence maybe-uninitialized warning in mongoose
Additionally list warnings in alphabetical order.
2025-01-05 15:30:41 +01:00
elexis e19a5eda9f Fix changing view to observer
`id` was compared to the wrong player.
This defect was introduced in 023527e56e.
2025-01-05 15:16:41 +01:00
Vladislav Belov 0467d27b07 Fixes slow-path texture conversion on RPI4.
RPI4 returns `false` for `textureCompressionBC` because it doesn't
support formats above BC3. As the Vulkan specification requires to
support all BC formats to have `true` for `textureCompressionBC`.
2025-01-05 00:27:02 +01:00
Vladislav Belov 54701868da Fixes GLES compilation. 2025-01-04 18:22:23 +01:00
elexis 88df5ec95f Don't focus on spies for non-following observers
Missing since introduction in e14ad3c771.
2025-01-04 18:01:29 +01:00
elexis 015aa0349b Fix vulnerability in spy-request
Introduced in d9d1f1bbeb.
This allowed draining an enemies metal resources by ordering spy-request
for that player.
Fixes #7230.
2025-01-04 18:01:29 +01:00
Lancelot de Ferrière c20ca02911 Fix AI errors when promoting an athenian spearman to champion.
Ideally the AI would try to carry on and recover gracefully but the code is setup in such a way that this seems like it would lead to a lot of different bugs down the line.

With help from @langbart on QA and code.

Fixes #7425
2025-01-04 15:44:05 +01:00
Lancelot de Ferrière a8fc3cf254 GameSettings: ensure savegameID is either a file name or undefined.
The current code could end up with savegameID being undefined, false, a filename string, or null depending on the code path taken.
Adapt C++ in consequence.
2025-01-04 15:01:27 +01:00
Lancelot de Ferrière fba5a23aad Fix sounds playing in the wrong places of the map
Introduced by a typo in f8afd49ae1.
Fixes #7345, reported by wowgetoffyourcellphone
2025-01-04 11:53:26 +01:00
Lancelot de Ferrière 3756e12701 Fix overlay renderer when changing displayed player.
Observers have the ability to change the currently displayed player, and this broke the logic of commit f3f695b90e.
By instead storing the displayed player in CmpOverlayRenderer, we can remove the workaround to set a 'dirty' flag as well.
2025-01-04 09:43:33 +01:00
Feldfeld b4443d396e Make Brit Crannog tooltip more accurate
Previously, arguably the tooltip hinted that naval technologies could be
researched which is not true. That could be a little confusing.
2025-01-03 22:15:17 +01:00
Feldfeld 5c25b6f644 Uniformize dock trainable entities
Docks are generic and have all ship entities. This comes to play notably when
they are captured. This is currently not the case for special docks (Crannog and
Cothon). For consistency they are given ship entities that are trainable by
other civilizations.

Also, the Crannog was not updated with the naval overhaul and still had the
trireme and bireme entities. They are now removed.

Fixes #7426
2025-01-03 22:15:17 +01:00
Itms 2482ecf9fe Sign and notarize macOS bundles 2025-01-03 17:05:15 +01:00
Itms 604d4ce29c Fix another macOS lib download source 2025-01-03 17:05:14 +01:00
Dunedan 33e9cd6126 Increase height of StoneButtons and TabButtons
This increases the height StoneButtons and TabButtons, so that a
double-spaced caption does fit on them without significant overflow.
Exempt from that are the StoneButtons resembling lists in the main menu
and the in-game menu, as changing their height didn't feel right and we
don't need double-spaced captions for them anyway, as they're wide
enough.

The height of StoneButtons got increased from 28px to 32px, while the
height of TabButtons got increased from 30px to 34px.
2025-01-03 16:33:51 +01:00
Lancelot de Ferrière 2f7ac026c1 Avoid idle 'flicker' because of regular formation regroups
Since 71a61d5f50, formations regularly regroup. However, units already at their correct offset should remain idle. This doesn't happen as we cannot check if we are at destination.
This exposes that and handles things properly... Unfortunately UnitAI has already left the IDLE state at this point, so we still get counted as no-longer idle for a turn.
To fix this, try and detect that particular situation without triggering infinite loops.
2025-01-02 16:59:13 +01:00
phosit a1a08f1890 Assign players to their slot from the savegame.
Based on a patch from @elexis.
2025-01-02 13:43:55 +01:00
phosit eafcb814cd Simplify playerassignments code
Deduplicate a check by moving it to isSlotAvailable.

Based on a patch by @elexis.
2025-01-02 13:43:55 +01:00
Stan fa19cb10fd Fix updating the OpenAL library
Some folders were not properly purged
2024-12-31 17:20:04 +01:00
Lancelot de Ferrière e24d01b0b1 Fix autostart issues reported by langbart in 2535e5f5b4 2024-12-31 10:09:07 +01:00
Lancelot de Ferrière e15ffd70b7 Fix Identity serialization following 533429e800
Failed to notice that name and controllable were sometimes changed.
2024-12-31 10:08:52 +01:00
phosit 9e740c84b9 Fix wrong variable name in caledonian_meadows
Defect introduced in 22a8f367f8.
2024-12-31 09:43:46 +01:00
phosit 54ce60e965 Fix error on large hights in Belgian Uplands
Defect introduced in 163063c2a4.
2024-12-31 09:43:46 +01:00
phosit 82513c9104 Catch all std::exception when loading a map
Since 0eed117e6d exceptions from the map generation script are rethrown
in the main thread but not all of them are catched.
2024-12-31 09:43:46 +01:00
wowgetoffyourcellphone da761ca501 Update the New Maps campaign file
Include new/updated skirmish maps and brand new random maps by @real_tabasco_sauce

Revert name and description strings only
2024-12-31 02:31:32 +01:00
Stan bce3a2a170 Fix the viking longship
- Apply Scale
- Rename mesh from Circle to viking_longship
- Remove useless material
- Add prop-projectile-prop point

Reported by: @Langbart
Fixes #7424
2024-12-31 02:25:35 +01:00
Stan 3499efe014 Add two missed files in previous commit 2024-12-30 23:42:34 +01:00
Stan df6ed56667 Add OpenAL Soft for macOS 2024-12-30 22:48:41 +01:00
Stan fd78034885 Mod Interface: Enable setting territory visibility
based on a patch by: aeonios

`off` means that the territory visibility cannot be changed
`hidden` means that it's hidden by default but can be enabled
`visible` means it's visible by default
2024-12-30 22:23:05 +01:00
Stan dc60a095dc Fix the statue_discobolus_cover.dae mesh
Reported by: @Langbart
- Add missing UVMap
- Apply scale
- Remove unused material
- Rename mesh from Plane.003 to discobolus_cover

Fixes #7423
2024-12-30 22:17:30 +01:00
Stan 7315b4e59f Rename Ship Combat Demo to match conventions
Reported by: @Langbart
Refs #7422
2024-12-30 22:12:54 +01:00
Dunedan 1aeb19b535 Improve alignment of in-game top menu
This improves the alignment of the items of the top menu in-game. Icons
are now better centered and don't overflow anymore and the build label
text doesn't stack on low resolutions anymore either.
2024-12-30 18:47:05 +01:00
phosit fb9b02a9ba Never change the names in the "Player Name" column
The intent of this branch was to not change the names when a saved game
is loaded. So that one can see who was where in the saved game.
It was implemented wrong: The names didn't change when no savegame was
loaded and changed when a saved game was loaded.

This commit make the soved game case and no saved game case consistent.

Defect introduced in b90280855f.
2024-12-30 15:23:31 +01:00
phosit 5c860c3121 Respect the enabledness in PlayerColor
There is no way to show the `PlayerColor` as disabled. As the player
color is vilible without this it can simble be hidden when it is
disabled.

Defect introduced in b90280855f.
2024-12-30 15:23:31 +01:00
phosit b52c1c137f Load the PlayerNames dependant on their origin
`PlayerData` didn't contain the playerNames when serialized because they
should not be loaded when a new game is made. This lead to the issue
that client didn't receive the initial player names of saved games.

Now `fromInitAttributes` gets as a second parameter whether the
initAttributus are from persistent settings.

Defect introduced in b90280855f.
2024-12-30 15:23:31 +01:00
phosit 199aa8ac35 Rebuild the selection list when rendering an ai
When a saved game gets loaded ai's aren't always selectable. This lead
to errors when an ai actually gets selected.

Defect introduced in b90280855f
2024-12-30 15:23:31 +01:00
phosit 8636e4d0fd Render GameSettingsWarning on construction
`GameSettingsWarning` where only rendered when the settings change. When
a saved game is loaded it's possible this setting is enablet without the
setting being changed.

Defect introduced in b90280855f.
2024-12-30 15:23:31 +01:00
phosit 4c48661b4f Disable mapbrowser when a saved game is loaded
Make it consistent with the "Browse Maps" buttow which is also
unavailable when a saved game is loaded.

Defect introduced in b90280855f.
2024-12-30 15:23:31 +01:00
phosit 96aa283e6a Make MapPreview always listen to map changes
When loading a saved game the user can't change the maps but when
receiving the initAttributes from the host the map is "changed".

Defect introduced in b90280855f.
2024-12-30 15:23:31 +01:00
Stan f14a98e26f Bump minimum macOS SDK to 10.15
According to https://firefox-source-docs.mozilla.org/widget/cocoa/sdks.html Firefox doesn't support anything lower than 10.15 at runtime. So neither do we.
Fixes #7370
2024-12-30 11:14:59 +01:00
Lancelot de Ferrière a6693e8c1f Fix samply profiling of SM JS code 2024-12-30 09:13:06 +01:00
Ralph Sennhauser 28b0801e82 Print diff for ruff-format if check fails
It's a bit hard for contributors to figure out what ruff-format is
unhappy about if all they get is a return status of non zero. Enable
printing a diff with suggested changes with the pre-commit hook.

Signed-off-by: Ralph Sennhauser <ralph.sennhauser@gmail.com>
2024-12-30 06:23:22 +01:00
Vantha 33111dc816 Fix phase names not updating on the structure tree
Reload all cached phase data when switching civ.
Add missing query for the generic phase technologies to the phase idents.
2024-12-29 22:21:28 +01:00
Vantha 314bc4185b Fix incorrect SpecificName syntax introduced in 94baa560b1 2024-12-29 22:21:28 +01:00
Dunedan 8a9813234e Remove GetFileMTime() 2024-12-29 09:32:17 +01:00
Dunedan 894e349ebf Add a deprecation warning for using GetFileMTime() 2024-12-29 09:32:17 +01:00
Dunedan ab0aee4cfa Use MD5 hash for splash screen version check
Instead of using the file modification date, this uses the MD5 hash of
the file holding the content of the splash screen for the version check.
This ensures the splash screen isn't unintentionally shown again when
just the modification date of the file changes.

Fixes #4399
2024-12-29 09:32:17 +01:00
Lancelot de Ferrière c2bb61fffc Fix terrain normals to account for angle 2024-12-28 13:25:07 +01:00
Dunedan 1268854587 Improve layout of the match summary screen
This improves the layout of the summary screen, so text and displayed
values fit better. By doing so this also removed the need to specify a
"verticalOffset" for values, as they get vertically centered now.
2024-12-28 12:10:07 +01:00