Commit graph

84281 commits

Author SHA1 Message Date
gfgtdf
58e7f6a7d3
fix #9561 OOS when undoingin multiplayer
previously in `undoable_action->undo(side_) ` the undo stack was not in sync with the relpay stack becasue the code called `undos_.pop_back();` before that and `resources::recorder->undo_cut` after that, this could confuse the code which sends replay commands to the other clients.
2024-11-10 21:38:37 +01:00
Nils Kneuper
ddbdf01588 updated Chinese (Simplified) translation 2024-11-09 18:34:36 +01:00
Nils Kneuper
ed37c7f807 updated Turkish translation 2024-11-09 18:33:30 +01:00
Nils Kneuper
a76f96e4ee updated Czech translation 2024-11-09 18:32:24 +01:00
Nils Kneuper
a8ecf3233b updated Bengali translation 2024-11-09 18:31:13 +01:00
Dalas121
63c161c81c
Changelog: create forestlion-rebalance.md
Changelog file for #9420
2024-11-09 07:55:49 -06:00
ForestDragon
a3f141c196
[Units] Adjust Forest Lion Stats (#9420)
hitpoints from 42 to 48
movement from 9 to 7
claws from 5x4 to 6x4, now usable on offense
bite from 15x2 to 9x2 charge, now usable in defense
arcane resistance from 20% to 10%
price from 21 to 30
2024-11-09 07:54:37 -06:00
Subhraman Sarkar
14302f6bff update changelog entries 2024-11-08 21:16:59 +05:30
Gunter Labes
b905c1aa4a
Allow accessing the old value in [set_var] formula= 2024-11-08 09:35:43 +01:00
Jonathan-Kelly
45662a2f83
Revert "SoF S7: fewer and slower enemy outriders" (#9521)
This reverts commit b3802f44ea.

Since commit 70df290 restores the Elvish Outrider to essentially its original stats, the 1.18 balance fix for this one campaign scenario is no longer useful.
2024-11-07 18:40:26 -06:00
Dalas121
9d9d2cd027
Sicarius - replace Deflect with Guard (#9532) 2024-11-07 18:26:21 -06:00
MechanicalDragon963
32b5570103
Improve Naga Guard line (#9529)
Redesigns the Naga Guard, Shield Guard, and High Guard to make their shield bash attack less redundant.

Also adds the new Unwieldy and Guard specials, and deprecates the Absorb special.
2024-11-07 16:33:23 -06:00
Charles Dang
4f97c10e35 Preferences: validate countdown time values when setting them 2024-11-07 11:10:13 -05:00
Charles Dang
37adb200e6 Display: small FPS counting fix
This is way more readable and more semantically correct. Essentially, instead of truncating the current and last timestamps to seconds and checking if we were "in" a different second, actually check the duration between the current frame and our last lap point .
2024-11-07 11:10:13 -05:00
Charles Dang
9a77b72aac Different approach to chrono::duration serialization
Since we're relying on free functions to parse and serialize time_points, it makes more sense to do likewise for durations rather than relying on a config_attribute_value member function. Leaves the assignment support for now.
2024-11-07 11:10:13 -05:00
Charles Dang
6dc65f6483 Campaignd: use chrono::system_clock instead of std::time_t
Includes adjustments to client code to likewise use chrono types. I decided to keep using time_t
(which is just an alias for long_long) for serializing time points. This avoids compatibility issues,
since we keep the same resolution (seconds since Unix epoch), and unless we're going to "properly"
store time points in config, the time_t's unitless value is a good a representation as any.
2024-11-07 11:10:13 -05:00
Charles Dang
b859060627 Add new refresh_rate pref to better handle --max-fps
The pre-processing for --max-fps was basically identical to what draw_manager::get_frame_length does.
This replaces the draw_delay preference with a new refresh_rate preference that more accurately describes
what is being set. video::current_refresh_rate will now take this preference into account, meaning the
build info report will correctly report player-set FPS limits.

The Limit FPS option in the prefs UI was also removed. When it was first introduced (cca79afe4b)
it specifically affected the map rendering code, not the rendering pipeline as a whole. With the 1.17
rendering refactor, this is no longer the case, and so its current usage as the lower bound for frametime
calculations did nothing (all it did was change the lower bound from 0 to -1 when enabled).

It might be worth adding a slider to the UI to dynamically set max fps, but that's a separate change.
2024-11-07 11:10:13 -05:00
Charles Dang
6fcf46a208 Events: remove pump_info
Only two places actually made use of the only thing it was useful for (the current tick count),
the countdown clock and the music thinker. The former was simpler to do without, and though it
was slightly useful for the latter, the music thinker really needs to be rethought.

The only thing this could be useful for is providing a stable timestamp for every process call.
That wasn't how it was designed, however. ticks() would populate its value the first time it was
called. Even if (as I considered doing) you change it to register the tick when constructing the
pump_info object, it's still easier (and easier to read) to just call steady_clock::now directly
as needed.
2024-11-07 11:10:13 -05:00
Charles Dang
12fa8f2844 Use standard chrono types consistently throughout the codebase
* Functions that return time values now return proper std::chrono::duration units (milliseconds,
  seconds, etc.). This removes the need to do manual unit conversions.
* Simple time-to-execute logging was replaced with `utils::optimer`.
* Most uses of `SDL_GetTicks()` have been replaced with `std::chrono::steady_clock`.
* Uses of events::pump_info::ticks() have been replaced with direct calls to steady_clock::now().
  This made the countdown_clock code significantly simpler. As for the music_tinker, that needs
  to be rethought wholesale.
2024-11-07 11:10:13 -05:00
Charles Dang
cd3e8d7652 Config: support time duration conversion and assignment 2024-11-07 11:10:13 -05:00
Charles Dang
7f4d2a437b Utils/Optimer: add a lap function 2024-11-07 11:10:13 -05:00
Gunter Labes
9181e4e298
Remove superfluous FIXME comment 2024-11-07 14:21:34 +01:00
MechanicalDragon963
e460d26dfc
Tweak Elvish Marshal Stats (#9512)
HP 68 -> 62
MP 5 -> 6
2024-11-06 20:50:32 -06:00
white-haired-uncle
05bf146866 GUI2 stacked_widget - add length operator 2024-11-05 21:59:24 -05:00
newfrenchy83
82cc6d979d moves alignment_str() to header and correct documentation 2024-11-04 19:09:59 -06:00
Gunter Labes
8b0909b24c Remove fallback logic from alignment_str() to work the same as alignment()
No caller was adjusted since IMO this is the correct behavior.
2024-11-04 19:09:59 -06:00
Subhraman Sarkar
c3f16b3294 reconvert file from original jpg and add metadata
removes bloat (13.7MB -> 4.3MB)
converted original jpg to webp using imagemagick, then applied cwebp -mt -m 6 -q 90 -alpha_q 100.
2024-11-04 16:51:49 +11:00
newfrenchy83
29e79c4235 Fixed an error in [filter_special] encoding
In special_id/type without the _'active' suffix only the encoding of the special in the attack is checked, and therefore the specials encoded in the [abilities] tags are de facto excluded, except that I forgot this logic in [filter_special] and I have to fix my error before updating the wikia.
2024-11-03 12:42:23 -06:00
Nils Kneuper
1aad482fe2 updated Norwegian translation 2024-11-03 18:02:44 +01:00
Nils Kneuper
e52d69cf67 updated Arabic translation 2024-11-02 12:54:35 +01:00
Subhraman Sarkar
0302dd8601 tutorial: UI improvements
uses portraits in the character selection and single click selection on pictures instead of buttons
also adds a dark background to hint messages to make them easier to read
adds arrow markers in the beginning on the units
2024-11-02 12:56:29 +05:30
Gothyoba
7fb0b8cdb3 Add Achievements to THoT 2024-10-31 12:38:00 -05:00
Wedge009
403dfbc673 Re-use translation strings from wesnoth-lib instead of duplicating them in wesnoth-editor.
Closes #9492. Bonus spelling correction.
2024-10-31 08:29:07 -04:00
Yoruma
88c6c13fdd Revert crashing code change part of #9292 2024-10-31 08:12:50 +05:30
Yoruma
0c2b035cc5 Fix with a little tricky 2024-10-31 08:12:50 +05:30
newfrenchy83
ee2bbc40cc refactor test for remove illuminates abilities. 2024-10-30 18:38:36 -05:00
newfrenchy83
7d5663b379 add a [remove_specials] tag in [effect] and [filter_special] to [has_attack/filter_weapon]
with this, it is possible to  simultaneously check specials with id and type, and/or other attributes for remove_specials effector filter_weapon
2024-10-30 18:38:36 -05:00
Thewodoros
ae5b2f0da6 Fix the attack_end event in Liberty S5
The event has to use side 3 because side 2 is idle. Also remove the dollar sign because IF_VAR doesn't work with it.
2024-10-31 10:26:23 +11:00
Subhraman Sarkar
e0e8b37880 help browser: add toggle for showing/hiding contents in 800x600 2024-10-30 13:28:58 -04:00
Gothyoba
c6853b021d
More New Titlescreen Images (#9466) 2024-10-30 11:30:28 -04:00
pentarctagon
5208905cdf fix indent 2024-10-28 13:19:42 -05:00
doofus-01
ccb079f05c
Update CI to check for XMP rather than EXIF - for PNGs only (#9435)
Addresses GIMP metadata editing limitations
2024-10-27 10:40:00 -07:00
newfrenchy83
b26f446d32 add changelog entry. 2024-10-27 09:14:45 -05:00
newfrenchy83
e905271c79 add modification specific to gender or variations
the old code don't work for replace advancement in [male/female] or [variation] tag
2024-10-27 09:14:45 -05:00
newfrenchy83
83d1bef0bc add amla advancement to [modify_unit_type]
Addresses https://github.com/wesnoth/wesnoth/issues/9309
when used, the amlas in [unit_type] are replaced by list of amlas in [modify_unit_type],i cannot done add [advancement] without erase amla already present.
2024-10-27 09:14:45 -05:00
Gothyoba
198b798e49
Make sure ELvish Race Description doesn't contradict WoF (#9505) 2024-10-27 13:57:27 +06:00
Charles Dang
61480df8eb Events: use native SDL handling for double click events
GUI2 still does its own handling with double clicks. This doesn't touch that. The default SDL handling is either 500ms (unchanged) or queried from the OS on Windows (an improvement). The click radius defaults to 32, which honestly seems like an acceptable adjustment.
2024-10-26 23:47:10 -04:00
Charles Dang
71dbaab868 Events/Pump Info: remove unused resize_dimensions member
This was set and never used. It was, at some point, I believe, but evidently got refactored out over the years.
2024-10-26 23:47:10 -04:00
Charles Dang
1ba3be778b Events: split off rate counting from pump_info::ticks
This interface was extremely confusing. pum_info is designed to set `ticks_` only once. This can lead to a situation (exemplified by the music code) where if ticks() is called multiple times in a row, the subsequent times with a counter, that counter would never be incremented since the condition that tests them short circuits on the is-ticks-not-set check.

Also, giving ticks() multiple side effects was very confusing.
2024-10-26 23:47:10 -04:00
SomeName42
44bb36d411 Sound source full_range and fade_range are now allowed to be 0. When fade_range=0 division by zero prevented. 2024-10-26 17:13:18 -04:00