[Commits] [wesnoth/wesnoth] e4eb0a: use ptr to impl for gamemap in game_board, avoidin...
GitHub
noreply at github.com
Wed Jun 11 20:42:23 UTC 2014
Branch: refs/heads/master
Home: https://github.com/wesnoth/wesnoth
Commit: e4eb0a3ede83ee338994708ebd48257627b47242
https://github.com/wesnoth/wesnoth/commit/e4eb0a3ede83ee338994708ebd48257627b47242
Author: Chris Beck <render787 at gmail.com>
Date: 2014-06-10 (Tue, 10 Jun 2014)
Changed paths:
M src/game_board.cpp
M src/game_board.hpp
M src/play_controller.cpp
M src/play_controller.hpp
M src/playsingle_controller.cpp
M src/scripting/lua.cpp
Log Message:
-----------
use ptr to impl for gamemap in game_board, avoiding map.h include
unit_map is modified in many places that don't normally include
map.hpp, so to avoid doing harm by adding this class, I am making
it hold a scoped pointer to the gamemap instead of an actual
gamemap. This results in very few changes.
- The implementation of game_board has to use the pointer.
- game_board must use copy and swap idiom
- lua get terrain function must pass strings to the game_board,
not enums, and we parse them as std::strings in game_board
instead of as c strings in lua api (which was a bit gross anyhow)
Commit: ac44e80a25d5c6959e479c77500136e619a6c9f9
https://github.com/wesnoth/wesnoth/commit/ac44e80a25d5c6959e479c77500136e619a6c9f9
Author: Chris Beck <render787 at gmail.com>
Date: 2014-06-11 (Wed, 11 Jun 2014)
Changed paths:
M src/game_board.cpp
M src/game_board.hpp
M src/play_controller.cpp
M src/play_controller.hpp
M src/playsingle_controller.cpp
M src/scripting/lua.cpp
Log Message:
-----------
Merge branch 'game_map_scoped_ptr_in_game_board'
Compare: https://github.com/wesnoth/wesnoth/compare/6757d25af16a...ac44e80a25d5
More information about the Commits
mailing list