54764 Commits

Author SHA1 Message Date
Ignacio R. Morelle
41b666fbfe gui1: Escape filenames in the file_menu menu that may contain WML formatting
This prepends font::NULL_MARKUP to file_menu menu entries so that any
WML formatting characters at the start of filenames such as "#foo.map"
('#' -> red font format specifier) are ignored.
2013-12-21 11:51:50 -03:00
David Mikos
cd8c83532b Make it so that sliders can be mouse wheel scrolled. 2013-12-22 00:16:27 +10:30
David Mikos
36b6b60beb Make middle click scrolling based on movement distance not screen centre. 2013-12-21 22:28:59 +10:30
Boldizsár Lipka
a1e6eb821a Fix custom options layout.
Pass the correct arguments to options_manager::layout_children.
2013-12-21 13:10:02 +01:00
Boldizsár Lipka
63a7446925 Hide custom option widgets in configure::hide_children. 2013-12-21 13:10:02 +01:00
ln-zookeeper
994960c6aa Flipped Haldric's ship horizontally. 2013-12-21 13:06:52 +02:00
ln-zookeeper
df175d747f Merge branch 'master' of https://github.com/wesnoth/wesnoth-old 2013-12-21 13:02:52 +02:00
ln-zookeeper
c4dca8e309 Typo fixes in drake race description. 2013-12-21 13:01:20 +02:00
Andrius Silinskas
09c73abdff Updated changelogs. 2013-12-21 10:43:28 +00:00
fendrin
9a44642689 Save villages and items. 2013-12-21 06:39:48 +01:00
David Mikos
13f8f2d86a changelog entry for Involution/iceiceice's new mp_settings LUA read-only table. 2013-12-21 15:52:18 +10:30
Coffee--
31e9c4ec0e Merge pull request #87 from cbeck88/new_lua_hooks
New lua proxy table "wesnoth.game_config.mp_settings".
2013-12-20 20:59:07 -08:00
Ignacio R. Morelle
23bdf9e1d6 CodeBlocks project update 2013-12-21 01:32:29 -03:00
Ignacio R. Morelle
673b3b08e0 Revert "remove unused util.*pp from wesnothd cb project"
This reverts commit c51ce084fe708c93a30742eb386cc001cc3d3d2f.
2013-12-21 01:21:52 -03:00
Ignacio R. Morelle
0ca924d734 Add missing serialization/compression.hpp from 553c56b2bd971535117530af6b3cc3644abf53c7 2013-12-20 23:51:38 -03:00
Ignacio R. Morelle
553c56b2bd preferences: Merge compress_saves and bzip2_savegame_compression options
Now that we have combo box options in Preferences -> Advanced, we can
finally present the saved game compression options in a user-friendly
fashion instead of having two separate options with an unclear
relationship.

However, in order to achieve this I had to move far more code than I am
normally comfortable with:

 * Moved the config_writer::compressor enum type to a separate header
   file, serialization/compression.hpp, in order to make it available to
   more units without pulling a bunch of heavy crap (such as the boost
   iostreams headers) that's normally unneeded. The new type is
   compression::format.

 * Added a compression::format_extension() function to determine a file
   extension string according to a compression type. This is needed more
   often than one would think, see below.

 * Changed all savegame-related classes to use the compression::format
   type instead of a single boolean flag and bzip2_savegame_compression
   queries. This is a code-heavy task by design.

 * Changed all code scattered around deciding whether to use ".gz" or
   ".bz2" for a save extension to use compression::format_extension()
   instead. This affects both saved game implementation and interface
   code for some reason (read: poor design).

 * Removed the bzip2_savegame_compression preferences option, reusing
   the previous compress_saves option for this feature, turning it from
   a boolean option to a string option ("none", "gzip", "bzip2",
   defaults to "gzip" per advanced_preferences.cfg).

 * preferences::compress_saves() became
   preferences::save_compression_format().

 * Without bzip2_savegame_compression, people who previously enabled
   bzip2 compression will revert to gzip compression. This seems to be a
   rare enough case to me to bother with providing backwards
   compatibility with a feature that only existed for [1.11.0, 1.11.8).

 * For preferences files from previous versions where compress_saves was
   set to either "yes" or "no", there will be a conspicuous value in the
   second column of the advanced preferences list, especially if they
   are using a translation; it'll be either "yes" or "no" as an
   untranslatable string. A value of "yes" is equivalent to "gzip", and
   a value of "no" is equivalent to "none". Any other unrecognized value
   is equivalent to "gzip". As soon as the user chooses a compression
   format again, one of the three supported values ("none", "gzip", or
   "bzip2") will be written to the compressed_saves attribute in the
   preferences file.

All in all, a ridiculously messy commit that's not particularly feasible
to break down into separate pieces because all of the involved code is
very closely related to the overarching feature that's being
implemented in it.

Note that the save_index currently only uses gzip regardless of whether
bzip2 is the current compression format choice. This was the case even
before this commit, and I'm not sure it's worth it to change it given
the potential CPU usage and the fact that save_index tends to be broken
most of the time anyway.
2013-12-20 23:36:46 -03:00
Ignacio R. Morelle
f1b4d2dc45 preferences: Add description and name_short attributes to combo options
name_short is used for the value labels entered into the main advanced
preferences listbox, which ideally shouldn't be stretched too much
sideways because GUI1 sucks. (Optional, used instead of name.)

description is entered as a second column value in the combo box items
list when available, and should be used as a short description of the
entry. (Optional, used in addition to name in the combo box popup view
only.)
2013-12-20 23:35:59 -03:00
Boldizsár Lipka
ec7516f366 Some text about mp mods in the help. 2013-12-21 03:08:45 +01:00
Boldizsár Lipka
04bdca51b7 Update the changelog. 2013-12-21 02:45:14 +01:00
Boldizsár Lipka
f59e0aaf78 Relabel buttons that switch between mp screens.
OK->Next in Create and Cancel->Back in Configure, as suggested by shadowm.
2013-12-21 02:30:20 +01:00
Boldizsár Lipka
4676c005f1 Initialize level metadata when adding the levels.
Level filters may use the metadata, so this is required for them to work correctly.
2013-12-21 02:30:20 +01:00
Boldizsár Lipka
94ba796055 Enable filtering by number of players. 2013-12-21 02:30:20 +01:00
ln-zookeeper
5d5aee134d New bigmaps and journey markers for TRoW. 2013-12-21 01:06:06 +02:00
anonymissimus
6142f5a687 fix dereferencing end iterator
exchange a and b in a && b
I wonder why it didn't show up until AI's changes though.
2013-12-20 21:31:41 +01:00
anonymissimus
26cc822ada #include <cctype> so MSVC finds the std::tolower version with 1 argument
For some reason MinGw didn't complain, perhaps some other header
includes it.
thx @thunderstruck
2013-12-20 21:31:27 +01:00
anonymissimus
9b96184604 vc project update 2013-12-20 21:31:20 +01:00
anonymissimus
c51ce084fe remove unused util.*pp from wesnothd cb project 2013-12-20 21:31:13 +01:00
anonymissimus
4622ba2350 fix compilation
u_int -> unsigned int
2013-12-20 21:30:54 +01:00
Bär Halberkamp
9ce2dfbc84 ran wmlindent 2013-12-20 19:59:12 +01:00
mattsc
c65d8d4ae1 Wolves MAI: fix bug that sometimes kept predators from attacking
The attacks aspect may only be modified if the avoid_type= key is set
in the [micro_ai] tag, otherwise all attacks get disabled.
2013-12-20 09:00:01 -08:00
Andrius Silinskas
084a354fda Updated label text in MP Create to improve consistency in style. 2013-12-20 16:40:06 +00:00
Andrius Silinskas
76d4a525d4 Added new CampaignWML attribute "require_campaign".
If attribute is set to "yes", players not having a campaign installed would not be
able to join a game.

Attribute defaults to "yes".
2013-12-20 16:40:06 +00:00
Groggy Dice
ea3b9580c4 update changelog with my recent contributions 2013-12-20 04:52:12 -05:00
Groggy Dice
4dcce0083b THoT Dwarvish_Loremaster: fix typo in apparently unnecessary magic comment
The irony of turning off spellcheck and misspelling spellcheck is obvious.

This magic comment is apparently unnecessary, though, since it wasn't
working, yet the file was not failing the spellcheck.
2013-12-20 04:52:09 -05:00
Groggy Dice
e22e204d67 wmllint: recognize characters in RECALL_XY 2013-12-20 04:52:05 -05:00
Groggy Dice
05cb8bab2c NR 05a - The Pursuit: add dialogue when a unit steps on the dungeon signpost
Most of the other signposts elicit a remark when a unit steps on them, but
curiously not this one.

Not only do I give the discovering unit a line, I have Tallin speak as
well. This may give alert first-time NR players a clue that this corridor
is important.

Some may prefer that players continue stumbling about, and object.
Unfortunately, there's no NR maintainer or active lord of prose to resolve
any difference of opinion.
2013-12-20 04:52:02 -05:00
Groggy Dice
6ec0163f6e add RECALL_XY macro to core
Many UMC projects have a macro for this function, but the name isn't
standardized (RECALLXY and RECALL_POS are also in use). However, regardless
of name, all these macros follow the "id x y" order, so for compatibility
I have kept that order. UMC authors started with a RECALL macro and added
coordinates, while the unit-generating macros have to organize a lot of
extra fields that are irrelevant to [recall].
2013-12-20 04:51:59 -05:00
Groggy Dice
29bc800600 add RECALL to core unit macros
Many UMC projects already have a RECALL macro.
2013-12-20 04:51:55 -05:00
Groggy Dice
9b03262d04 parse whofield macros to recognize unit id fields
Also, explain usage of the "whofield" magic comment in the introduction
2013-12-20 04:51:52 -05:00
Groggy Dice
5c85e80487 create magic comment "whofield" for id fields of non-core macros
Although we can now auto-recognize characters in the core NAMED_*UNIT macros,
campaigns may have their own recruit/recall macros. This comment will tell
wmllint which field contains the macro's id.

The basic format is 'wmllint: whofield <macro> <num>'. This commit sets up the
dictionary, the next commit will actually parse the macros. It will explain
more details about how to use this magic comment in wmllint's introduction.
2013-12-20 04:51:48 -05:00
Ignacio R. Morelle
db95b23db5 preferences: Implement a "combo" advanced preferences entry type
Usage example:

    [advanced_preference]
        field=test_combo
        name= _ "Combo test"
        type=combo
        default=option1
        [option]
            id=option1
            name= _ "Option #1"
        [/option]
        [option]
            id=option2
            name= _ "Option #2"
        [/option]
        [option]
            id=option3
            name= _ "Option #3"
        [/option]
    [/advanced_preference]

NOTE:

Now that there are more than two types of advanced preferences entries,
a problem with the saving and restoring of the previous screen surface
contents with the three GUI1 widgets involved (the checkbox, the combo,
and the slider) has appeared, resulting in the advanced preferences
slider glitching into view under certain conditions. This is apparently
related to the widget hiding/unhiding order; for example,
hiding/unhiding the advanced preferences combobox after the slider and
its label results in the combobox glitching into view when switching the
advanced preferences list selection instead.
2013-12-20 06:25:42 -03:00
mattsc
70954b7ba2 Update changelogs and release notes with SotBE changes 2013-12-19 20:58:17 -08:00
fendrin
91b5a57449 Renamed "current_tod" attribute of [time_area] to match the global one.
"current_tod" and "current_time" served the same purpose, one at
scenario toplevel, the other inside of [time_area].

For the sake of consistency and for enabling the usage of the same
schedule macros in both cases, they are now both called "current_time".
2013-12-20 04:45:18 +01:00
fendrin
de239ae2e5 Save [time_area]s id only if it is not empty. 2013-12-20 04:29:31 +01:00
fendrin
8604edd226 Save the id of [time_area]s into the savefile.
This should fix removing [time_area]s in a loaded game.
2013-12-20 04:20:43 +01:00
Ignacio R. Morelle
7e965dbdd2 Fix vague/misleading error messages for non-existent color palettes
Fixes bug #20439.
2013-12-19 23:15:11 -03:00
Ignacio R. Morelle
c7cacb1d5a gui1: Display unit overlays and crowns in the Recall dialog preview pane
This incidentally would allow displaying overlays for other preview
panes in the future (e.g. the main sidebar) since most of the required
functionality was implemented on the unit_preview_pane base class.
2013-12-19 22:38:24 -03:00
Ignacio R. Morelle
7883f366df gui1: Display unit overlays and crowns in the Recall dialog's list 2013-12-19 22:38:24 -03:00
Ignacio R. Morelle
2d41e10b00 Move leader crown path to a constant and static public method 2013-12-19 22:38:23 -03:00
fendrin
f979609ccf area= SLF attribute support for filtering by [time_area]s. 2013-12-20 02:27:44 +01:00