`[terrain_mask]` had multiple unexpected behviours, see for example #3364
in parituclar `wesnoth.wml_actions.terrain_mask { x =2, y=2, mask="Ww"}`
will change the tile at (1,2) instead of (2,2), so instead of reusing
the old terrain mask code i wrote a new function that behaves as one
would expect. `wesnoth.terrain_mask` does not have a `border=` parameter
but a `is_odd` parameter that specifies that a map is in the odd format
__ __
/00\__/20\__
\__/10\__/30\
/01\__/21\__/
\__/11\__/31\
/02\__/22\__/
\__/ \__/
instead of the even map format
__ __
__/10\__/30\
/00\__/20\__/
\__/11\__/31\
/01\__/21\__/
\__/12\__/32\
\__/ \__/
(Monospaced font required to see ascii images.)
The lua function also has a lua interfacte, meaning it does not take wml
tables but normal lua tables making it easier to use from lua code.
(cherry-picked from commit a3367ee8489608a6fff42a69fb026933571848b7)
boost::ptr_vector has some nice features, but vector<unique_ptr> is still
easier to use for most people basicially becasue people know it better.
Also boost::ptr_vector does not support move ctors and also does not
use std::unique_ptr, probably because it tries to stay compatible with
c++03 so one has to use 'ptr_vector::auto_type' with it instead which
has a different interface than std::unique_ptr
(cherry-picked from commit 7e2dc296ba2fd3900a46ab3a0bbb120e856e0ada)
for extra safety we add code to ensure undo=no for [speak] commands to the client aswell, this is not really needed as i just added a code that sets undo=yes to the server code, but it's an advantage to be able to safely connect to older servers aswell.
(cherry-picked from commit c685031d1c41d89897bbd380b50ef3e02984bcde)
previously the server would send [speak] commands that had no undo=no attributes so that the game would remove the speak command from the replay instead of the actual undoable action when undoing an action.
(cherry-picked from commit 02bed5c0335893542f5f3732ea013ab1ca705c55)
This new implementation works more reliably, avoids spawning subshells, and is faster.
(cherry-picked from commit 4282ee3fdc50223e62af2ad60b386b21b6fd690f)
code it as & to avoid a pango warning in stderr
3ec26df changed it previously to '+' to work around that warning
also change it for the untranslatable strings in the credits
[ci skip]
(cherry-picked from commit cd5b3f785e137f66f9d282c8348a6ad877e48d2f)
Turns out that a t_string doesn't automatically obtain the correct
translated value. Thus, I'll simply get it by calling
translation::dsgettext() directly. I also changed the translated string to
be used in the tab label as well.
(cherry-picked from commit 395eaf5251d50373d23bd8f53b7b254683a3dfed)
The original text that referred to Knalga was confusing if the
player thought of Knalga as "dwarvish territory", and most of
the campaign's scenarios have been somewhere in Knalga.
(cherry-picked from commit a6bd0c87ac9ee4066ddad2700182778a0658f4e2)
Updated to [allow_undo], because the hint message shouldn't block undoing a
recall. Recruiting can't be undone, even with [allow_undo], so this isn't
allowing a cheater's opportunity to recruit units with desired traits.
(cherry-picked from commit 66c56403db61acd1621d2b4d78e8f848c826540b)
Anyone who prefers to be credited some other way (or whose name I misspelled) can feel free to open another PR
@Byteron @rrigby @DisherProject @Ferk @Konrad22 @lilinitsy @UnwiseOwl @bandita137@Ordoviz
(cherry-picked from commit ff4e1b2e61ab99be12e1b36cbc954e3f66efa116)