mirror of
https://github.com/wesnoth/wesnoth
synced 2025-04-28 23:22:36 +00:00
Fixed RCA AI not loading for scenarios with a custom [ai] config,
...especially when the RCA AI is still the only choice available to the user in the dropbox. (Fix for bug #16607.)
This commit is contained in:
parent
07ccfc6be4
commit
429c65fdbc
@ -170,10 +170,10 @@ connect::side::side(connect& parent, const config& cfg, int index) :
|
||||
|
||||
update_faction_combo();
|
||||
|
||||
if (const config &ai = cfg.child("ai"))
|
||||
ai_algorithm_ = ai["ai_algorithm"].str();
|
||||
else if (!parent_->ai_algorithms_.empty())
|
||||
if (!parent_->ai_algorithms_.empty())
|
||||
ai_algorithm_ = parent_->ai_algorithms_[0]->id;
|
||||
else if (const config &ai = cfg.child("ai"))
|
||||
ai_algorithm_ = ai["ai_algorithm"].str();
|
||||
else
|
||||
ai_algorithm_ = "default";
|
||||
init_ai_algorithm_combo();
|
||||
|
Loading…
x
Reference in New Issue
Block a user