The cause of the crash was that the active_menu_ variable was set to UNIT_FACING after the unit facing setting is finished. When clicking the menu it was looking for a unit because of the value of the active_menu_ variable and on line 670 the assert failed because it could not find one. Setting active_menu_ to MAP after the unit facing is set fixes this.
This commit is contained in:
parent
4e1666c7a1
commit
a5e17f770d
1 changed files with 1 additions and 0 deletions
|
@ -770,6 +770,7 @@ bool editor_controller::do_execute_command(const hotkey::ui_command& cmd, bool p
|
|||
assert(un != get_current_map_context().units().end());
|
||||
un->set_facing(map_location::direction(index));
|
||||
un->anim_comp().set_standing();
|
||||
active_menu_ = MAP;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue