remove old code handling controller=network/network_ai
controller= doesn't support 'network' or 'network_ai' values anymore, so these can be removed.
This commit is contained in:
parent
803c54dacc
commit
c37c5d6434
1 changed files with 1 additions and 9 deletions
|
@ -898,18 +898,10 @@ side_engine::side_engine(const config& cfg, connect_engine& parent_engine,
|
|||
update_controller_options();
|
||||
|
||||
// Tweak the controllers.
|
||||
if (cfg_["controller"] == "network_ai" ||
|
||||
(parent_.state_.classification().campaign_type == game_classification::CAMPAIGN_TYPE::SCENARIO && cfg_["controller"].blank()))
|
||||
if (parent_.state_.classification().campaign_type == game_classification::CAMPAIGN_TYPE::SCENARIO && cfg_["controller"].blank())
|
||||
{
|
||||
cfg_["controller"] = "ai";
|
||||
}
|
||||
//this is a workaround for bug #21797
|
||||
if(cfg_["controller"] == "network" && !allow_player_ && parent_.params_.saved_game)
|
||||
{
|
||||
WRN_MP << "Found a side controlled by a network player with allow_player=no" << std::endl;
|
||||
cfg_["controller"] = "ai";
|
||||
}
|
||||
|
||||
if(cfg_["controller"] != "human" && cfg_["controller"] != "ai" && cfg_["controller"] != "null") {
|
||||
//an invalid contoller type was specified. Remove it to prevent asertion failures later.
|
||||
cfg_.remove_attribute("controller");
|
||||
|
|
Loading…
Add table
Reference in a new issue