Commit Graph

84995 Commits

Author SHA1 Message Date
Charles Dang
d2da8b0fc7 Help: use an em dash to indicate no weapon special 2025-03-06 14:08:51 -05:00
Tahsin Jahin Khalid
cf3eaff74c TSG: sg_help.cfg: use correct variable call
closes #10003
2025-03-06 14:01:21 -05:00
Charles Dang
0d407eacd0 GUI2/Label: remove title_script definition
The help browser now uses the standard title definition. This makes its appearance consistent with other title elements in that theme. Before, it had the wrong color in the celes theme and was the only title in the parchment theme using the script font.
2025-03-06 13:12:49 -05:00
Charles Dang
101dff854e GUI2/Canvas: use config::attribute_value for text
For some reason, if we store a t_string in the class and attempt to parse it later, it breaks text boxes (text will be there but not render) (see #9995). Using an std::string does not have that problem. I don't know why.

I considered a variant<typed_formula, t_string>, but since attribute_value is a variant under the hood, it seemed simpler to just use it directly. If that turns out to be a performance hit, we can deal with that later...

Closes #10001
2025-03-06 12:45:00 -05:00
Charles Dang
b655186ec4 GUI2/Story Screen: bump title size 2025-03-06 11:47:27 -05:00
Charles Dang
46be4a2bcc Fix duplicate file suffixes 2025-03-06 11:35:17 -05:00
Subhraman Sarkar
e1e7e2c0b9 canvas: keep a verbatim copy of text_ (closes #9995)
For some reason doing it all in `draw()` causes #9995.
2025-03-06 19:34:15 +05:30
pentarctagon
3a007c0fb4 Correctly set use_map_settings
Fixes #9993
2025-03-05 21:50:40 -06:00
Charles Dang
6c7e17b5ca GUI2/Tips: simplify code
Corrects a mistake I made way back in dcb996566e, which was that a tip is supposed to be shown if you encounter *any* of the filter units, not *all* of them.
2025-03-05 13:20:29 -05:00
Charles Dang
ebffc334ee GUI2: remove GUI_WINDOW_PERC_FIXED_SIZE_CENTERED 2025-03-05 13:13:09 -05:00
Subhraman Sarkar
b40edadd1a update changelog with info from #9957 2025-03-05 22:11:53 +05:30
Charles Dang
f292c946d8 GUI2/Definition: avoid redundant map search 2025-03-05 11:28:40 -05:00
Subhraman Sarkar
0d43a49c71 unit: add dismissable and block_dismiss_message
Used in conjunction with `Dismiss` button on Unit Recall Dialog.
2025-03-05 21:55:53 +05:30
Tahsin Jahin Khalid
96e32d8dae
THoT-S3: make AI sides smarter (#9992)
- Side 2 will be less reckless and more defensive
- Side 3 will avoid making stupid moves, like placing units on water for easy kills

Co-authored-by: Tahsin Jahin Khalid <5283677+knyghtmare@users.noreply.github.com>
2025-03-05 22:22:39 +06:00
Charles Dang
968e9b95e1 GUI2: rework init codepath for a second time
Resolves #9973. Reworks #9974, since I misunderstood how schema validators worked. They are indeed stateful and you need one instance per read call.

I also decided to do away with the global macro context because I do *not* want to have to deal with people claiming the core GUI2 macros constitute a public API (nor do we want macros from one addon affecting the themes in another in the unlikely event that multiple people make gui2 themes.)
2025-03-05 10:57:53 -05:00
Gunter Labes
ea52702bd0
Update runner image 2025-03-03 18:03:05 +01:00
Subhraman Sarkar
de4c22efef canvas: fix whitespace 2025-03-03 20:30:07 +05:30
Subhraman Sarkar
c9cbc9a793 canvas: simplify verbatim parsing of text 2025-03-03 20:17:27 +05:30
Charles Dang
3fa8f38a9c GUI2/Help: bump text area width 2025-03-02 23:12:27 -05:00
Charles Dang
da414d75e3 GUI2/Help: set max width for topic names (resolves #9886)
Not a perfect fix by any means (I really don't like having to add new label definitions just to set max_width), but this is currently the canonical way to do so that doesn't involve characters_per_line.
2025-03-02 21:47:28 -05:00
Charles Dang
4c6bbe1342 MP/Lobby: alow profile and match history buttons to grow
Was fine on the old theme (in English, at least), but there was weird empty space on the new modern theme.
2025-03-02 16:01:17 -05:00
Charles Dang
0447a0ae88 Game Lua Kernel: remove orphaned function declarations 2025-03-02 12:43:48 -05:00
Charles Dang
caa5683818 CI: run boost unit tests on a release build only
The debug CI build is consistently the last CI job to finish, usually behind even the Windows and Mac jobs.
2025-03-02 11:00:43 -05:00
Subhraman Sarkar
ec765138ac
Editor Adjustments (#9957)
Map/Scenario Editor: Adds a "Convert to Scenario" option to File menu. Adds enough sides based on starting positions on map.
Update help: Save As Scenario -> Convert to Scenario
2025-03-02 21:01:07 +05:30
Charles Dang
16830f8ab4 WFL: allow re-defining functions instead of silently failing
Closes #9908, fixes #9795. This change is #9908 done `insert_or_assign` instead of an emplace check. Credit to @Mahoyomu for the fix.
2025-03-02 10:16:53 -05:00
Charles Dang
55dc0a8215
GUI2: harden theme definition parsing (#9974)
- Ensure current_gui is a valid iterator after calling init(). It should match default_gui
- Ensure current_gui is always set to guis.end() if the requested theme isn't found in switch_theme().
  It's initialized as such in gui_definition.cpp, but we shouldn't rely on that always being the case,
  especially in a function that changes it.
- Only create one schema validator for all themes. Previously, it would have been created anew for
   each addon with a custom theme.
- Add explicit exception handling for an invalid schema path or invalid gui2 entry point
- Add explicit warning for addon themes with the id "default"
- Catch `wml_exception` when creating gui_definition objects for all themes (previously, this was only
   caught for add-on themes)
- Adjust error messages
- Fix duplicate theme errors when reloading cache (addresses one part of #9781). GUI2 definition
  changes now take effect without the need to restart the entire game. A cache reload is sufficient.
- Use `_main.cfg` for core theme entry points
- Include macros at global core GUI2 score instead of only in the default theme (they were always
  available to both themes, this just makes that clearer)
2025-03-02 00:12:32 -05:00
Charles Dang
e8c164d377 Fix schema whitespace 2025-03-01 11:41:21 -05:00
Gunter Labes
3db91fc0d2
Typo fix 2025-03-01 11:18:59 +01:00
Wedge009
b8ec44a77e EI S11: Improvement upon 7e461ae2f5.
[ci_skip]
2025-03-01 10:39:21 +11:00
Gothyoba
de6ef82420
Note that iOS/Android versions are currently unmaintained in readme (#9961)
Co-authored-by: Gunter Labes <soliton@wesnoth.org>
2025-02-28 08:59:04 +05:30
Dalas121
6234ef1453
Update Firebomb Ant and Grand Dragonfly XP (#9963)
Increase XP from 80 to 100, which is more standard for L2 units with no L3 advancement.
2025-02-27 08:30:26 -06:00
Yoruma
a0cad9b0c3 Squashed and Fix the unit teleport issue by moving code to mouse_event 2025-02-26 19:53:29 -06:00
Gunter Labes
7e461ae2f5
Typo fix 2025-02-26 23:56:43 +01:00
Gunter Labes
9aec16a801
Add map dimension info
Always generate a comment even if image upload failed and add API response for easier debugging.
2025-02-26 23:51:23 +01:00
Refumee
63409f7492
TDG: update Saurian Juvenile sprites (#9945)
Updating the sprites for the saurian juvenile in TDG, and added a bobbing standing animation. Colorset of the Saurians respects the ColorMap of the Saurians with some exceptions in the clothing.
2025-02-26 12:27:10 -06:00
Subhraman Sarkar
55c7b474b4 help: link base and overlay terrains in terrain help pages (#9456) 2025-02-26 00:58:38 -05:00
Wedge009
20c1692c8c Only attempt to load .cfg scenarios (closes #4363) 2025-02-26 13:51:00 +11:00
Subhraman Sarkar
59ede591f3
lua api: expose male/female names for races (#9955)
Resolves #9954
2025-02-25 09:01:10 -05:00
Gunter Labes
80f37cf62b
Remove obsolete define
See 5431810b62.
2025-02-25 13:53:16 +01:00
Gunter Labes
8e7947c6c8
Remove useless TODO comment 2025-02-25 13:23:19 +01:00
Dalas121
cfed9ef69e
TDG: remove silent raven speed reduction, and use TRAIT_SLOW instead
TDG gives Delfador access to a loyal raven/dire raven/war harbinger. Currently, the speed for this unit is capped at 6, to prevent it from being overly-powerful when compared with other options.

revolting_peasant pointed out that this speed cap makes the raven's stats inconsistent with the numbers in "view unit type". To resolve that, this PR replaces the speed cap with {TRAIT_SLOW}.
2025-02-24 16:24:59 -06:00
Charles Dang
0555ce3d08 Lua/Team: fix village_gold setter setting village_support (fixes #9952)
Typo originally part of cb1853b4bc
2025-02-24 17:10:45 -05:00
newfrenchy83
43c751971a add 'invulnerable' status for prevent unit die during tests 2025-02-24 10:44:41 -05:00
Charles Dang
9ef8c90767 Bump min Boost version to 1.70 2025-02-24 01:05:16 -05:00
Aardvark
fbe2166c33
World Conquest: Remove hard coded trainer indices (#9408)
---------

Co-authored-by: Richard <93877353+richardalbee@users.noreply.github.com>
2025-02-23 15:37:26 -06:00
Charles Dang
34595668b4 Fixup 98c21e1 (re-add theme check) 2025-02-23 15:44:29 -05:00
Charles Dang
1975ffdadc GUI2/Achievements: set max_width for title in label definition
Also some border tweaks
2025-02-23 15:04:20 -05:00
Charles Dang
75a47689ea GUI2/Achievements: code cleanup, use VGETTEXT 2025-02-23 15:03:32 -05:00
Charles Dang
98c21e1bf2 GUI2/Definition: make get_control more readable 2025-02-23 15:02:57 -05:00
Dalas121
58030bde84
TDG: some S00 onboarding improvements (#9941)
Based on: https://forums.wesnoth.org/viewtopic.php?p=696551#p696551

Makes the "Delfador does not use XP to level-up" message less likely to appear in the first scenario, and elaborates on how Delfador does level-up.
2025-02-23 08:28:14 -06:00