Fix my breakage of silene's 2009-07-26T16:56:40Z!guillaume.melquiond@gmail.com.
This commit is contained in:
parent
cdb081a1c3
commit
88d3c95846
1 changed files with 2 additions and 3 deletions
|
@ -671,12 +671,11 @@ void recruit_result::do_execute()
|
|||
recorder.add_recruit(num_,recruit_location_);
|
||||
replay_undo replay_guard(recorder);
|
||||
unit_type_data::unit_type_map::const_iterator u = unit_type_data::types().find_unit_type(unit_name_);
|
||||
map_location loc = recruit_location_;
|
||||
const events::command_disabler disable_commands;
|
||||
const std::string recruit_err = find_recruit_location(get_side(), loc);
|
||||
const std::string recruit_err = find_recruit_location(get_side(), recruit_location_);
|
||||
if(recruit_err.empty()) {
|
||||
const unit new_unit(&info.units, &u->second, get_side(), true);
|
||||
place_recruit(new_unit, loc, false, preferences::show_ai_moves());
|
||||
place_recruit(new_unit, recruit_location_, false, preferences::show_ai_moves());
|
||||
statistics::recruit_unit(new_unit);
|
||||
get_my_team(info).spend_gold(u->second.cost());
|
||||
// Confirm the transaction - i.e. don't undo recruitment
|
||||
|
|
Loading…
Add table
Reference in a new issue