[Commits] [wesnoth/wesnoth] dec677: Refactor unit type ability metadata storage
GitHub
noreply at github.com
Mon Feb 19 10:49:01 UTC 2018
Branch: refs/heads/master
Home: https://github.com/wesnoth/wesnoth
Commit: dec677f2c549d954af5f52ee86ea1d52bc594492
https://github.com/wesnoth/wesnoth/commit/dec677f2c549d954af5f52ee86ea1d52bc594492
Author: Charles Dang <exodia339 at gmail.com>
Date: 2018-02-19 (Mon, 19 Feb 2018)
Changed paths:
M src/gui/widgets/unit_preview_pane.cpp
M src/help/help_impl.cpp
M src/help/help_impl.hpp
M src/help/help_topic_generators.cpp
M src/reports.cpp
M src/units/abilities.cpp
M src/units/types.cpp
M src/units/types.hpp
M src/units/unit.hpp
Log Message:
-----------
Refactor unit type ability metadata storage
This fixes #1774. Essentially, I made the help browser use both ability name and ids when
deciding which ones to add topics for. To facilitate that, I've gotten rid of the separate
vectors for ability names and descriptions and consolidated all the data into a single
ability_metadata struct to unit_type. It still needs to be expanded for use in the unit
class (which I intend to do), which is why it has a whole bunch of fields I don't use.
I've also totally refactored the ability topic generation code in the help browser.
Commit: b477f40a7f05acb97603921e05272521e240c96e
https://github.com/wesnoth/wesnoth/commit/b477f40a7f05acb97603921e05272521e240c96e
Author: Charles Dang <exodia339 at gmail.com>
Date: 2018-02-19 (Mon, 19 Feb 2018)
Changed paths:
M src/image.cpp
Log Message:
-----------
Removed direct use of boost::hash_value
std::hash suffices. boost::hash_combine is still the easiest method for combining
hashes, though.
Compare: https://github.com/wesnoth/wesnoth/compare/257bb415efc7...b477f40a7f05
More information about the Commits
mailing list