Index: src/ai/ai_gui.cpp
===================================================================
--- src/ai/ai_gui.cpp (revision 27601)
+++ src/ai/ai_gui.cpp (working copy)
@@ -532,7 +532,10 @@
{
if (StrEmpty(str)) return;
ScriptConfigItemList::const_iterator it = this->ai_config->GetConfigList()->begin();
- for (int i = 0; i < this->clicked_row; i++) it++;
+ for (int i = 0; i < this->clicked_row; i++) {
+ it++;
+ if (!_settings_client.gui.ai_developer_tools && (it->flags & SCRIPTCONFIG_DEVELOPER) != 0) it++;
+ }
if (_game_mode == GM_NORMAL && ((this->slot == OWNER_DEITY) || Company::IsValidID(this->slot)) && (it->flags & SCRIPTCONFIG_INGAME) == 0) return;
int32 value = atoi(str);
this->ai_config->SetSetting((*it).name, value);
@@ -543,7 +546,10 @@
{
assert(this->clicked_dropdown);
ScriptConfigItemList::const_iterator it = this->ai_config->GetConfigList()->begin();
- for (int i = 0; i < this->clicked_row; i++) it++;
+ for (int i = 0; i < this->clicked_row; i++) {
+ it++;
+ if (!_settings_client.gui.ai_developer_tools && (it->flags & SCRIPTCONFIG_DEVELOPER) != 0) it++;
+ }
if (_game_mode == GM_NORMAL && ((this->slot == OWNER_DEITY) || Company::IsValidID(this->slot)) && (it->flags & SCRIPTCONFIG_INGAME) == 0) return;
this->ai_config->SetSetting((*it).name, index);
this->SetDirty();