previously the first image timer would not be cleared when the user restarted
the part, which in particular caused UB if the story_viewer was closed
before all timers have finished.
fixes#3838fixes#3837
The feature was never added, a deprecation message saying that it's been
removed is the closest option to the situation. While terrain.cpp itself
supports vision_alias, it was never added to the calculations in movetype.cpp,
therefore it never affected units' vision. It's also not shown in the help
about the terrain.
This doesn't affect the features of units having vision costs different to
movement costs, or of units having a different number of vision points to
movement points, both of which are still supported.
While I'd encourage anyone who wants to implement vision_alias to do so, at the
moment I feel that the still-supported features in the same area haven't been
explored yet, and that vision_alias isn't going to developed before 1.16.0 is
released.
If a unit has an attack with ability to poison/slow and a high number of
strikes (24 in the provided test case), the calculated probability of the
other unit being hit and therefore poisoned/slowed could exceed 100 % due to
floating point rounding errors. It caused an assertion failure if the AI
simulated another fight for the target unit afterwards.
Fixed by limiting the probability of being hit to 100 %.
Now, if no action is provided and the current side's controller or proxy controller is the AI, the side is changed to fully human control (same as `:droid <side> off`). If no action is provided and neither the controller or proxy controller of the current side are controlled by the AI, then the controller is set to human and the proxy controller set to AI(same as `:droid <side> on`).
Fixes#4308
Fixes#4253.
The schema's validation of ranges now rejects negative numbers, because the C++
code doesn't support them (both before and after this commit):
* utils::parse_range("-7") will return {0,0}, because std::stoi("") throws invalid_argument.
* src/map/location.cpp will parse it as -7, but that will never match an on-map coordinate
This removes all of the "do not translate part^string part" strings, replacing
them with more help in English and a place for translators to explain what the
untranslatable "all" means. For commands where the usage has notes about the
arguments, this embeds the \n in the strings passed to register_command; that
seems a reasonable balance between usability and effort to implement it.
Cherry-picking between 1.14 and 1.15: In 1.14.x, the "droid" command only has
options "on" and "off". The "full" option was only added in 1.15.
Remove unnecessary blank lines and debugging comments
- Adds a preferences entry in the multiplayer/alerts menu so sounds and desktop notifications can be toggled.
Reformat a few points for consistency
Have desktop notification show name and scenario of new game
Have desktop notification show name and scenario of new game
Update desktop notifications to use VGETTEXT for translations
(cherry picked from commit af71dbf1b1)
(cherry picked from commit a2d9943286)
previously the clint woudl send a [update_game] to the
server before sending [store_next_scenario] whcih set
game::started_ to false and this disabled game::save_replay()
Now we instead set started_ to false after save_replay() is called
I also don't really see the point of calling update_side_data()
and describe_slots() before the new level data is available so i just
removed these calls. (the call to game::update_game())
now wesnoth.require is able to detect when the same file is
required two times using different names (like a/../a/b.lua
a/b.lua) and will only execute it once.
for this a new function wesnoth.canonical_path was added
While I understand the reason it's here, it's been over a decade, no other user handlers have been added, and there's no indication any others will be added. Therefore, it doesn't seem like there's much of a reason to keep this code around.
This still requires a huge surface to render all of the text on to,
but is an easier fix than redesigning the credits screen.
This removes the only caller of utils::vertical_split, which is why
that utility function is also removed.