Loading

Revision differences

Old revision #pytpi3bkwNew revision #pcgnsbddr
1this->SetWidgetDisabledState(WID_AIC_CHANGE, ((this->selected_slot == OWNER_DEITY && _game_mode == GM_NORMAL) || this->selected_slot == INVALID_COMPANY) ||    (this->selected_slot <= MAX_COMPANIES && _game_mode == GM_NORMAL && Company::IsValidAiID(this->selected_slot) && !Company::Get(this->selected_slot)->ai_instance->IsDead())); 1bool gs_slot = this->selected_slot == OWNER_DEITY;
   2bool dead_ai_slot = IsEditable((CompanyID)(this->selected_slot)) && Company::IsValidAiID(this->selected_slot) && !Company::Get(this->selected_slot)->ai_instance->IsDead();
   3this->SetWidgetDisabledState(WID_AIC_CHANGE, _game_mode == GM_NORMAL && (gs_slot || dead_ai_slot) || this->selected_slot == INVALID_COMPANY);