Skip to content

Commit

Permalink
fixup 0f5876f
Browse files Browse the repository at this point in the history
There was a small mistake here: The unit constructor
which takes a unit type first and 3 other parameters,
has the 4th one being an optional gender, and the
third a bool. fake_unit had a constructor mapping to
this, which sets the third to false. I over looked
this when factoring out fake_unit, but it only
generates a warning to cast enum to bool on MSVC
compilers.
  • Loading branch information
cbeck88 committed Jun 25, 2014
1 parent 9757a2d commit 6ec86c9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/game_events/action_wml.cpp
Expand Up @@ -239,7 +239,7 @@ namespace { // Support functions
unit_race::GENDER gender = string_gender(cfg["gender"]);
const unit_type *ut = unit_types.find(type);
if (!ut) return fake_unit_ptr();
fake_unit_ptr fake = fake_unit_ptr(UnitPtr(new unit(*ut, side_num, gender)));
fake_unit_ptr fake = fake_unit_ptr(UnitPtr(new unit(*ut, side_num, false, gender)));

if(!variation.empty()) {
config mod;
Expand Down

0 comments on commit 6ec86c9

Please sign in to comment.