equal
deleted
inserted
replaced
3771 DeleteWindowById(WC_BUY_COMPANY, _current_player); |
3771 DeleteWindowById(WC_BUY_COMPANY, _current_player); |
3772 if (IsLocalPlayer()) { |
3772 if (IsLocalPlayer()) { |
3773 AskExitToGameMenu(); |
3773 AskExitToGameMenu(); |
3774 return; |
3774 return; |
3775 } |
3775 } |
3776 if (IS_HUMAN_PLAYER(_current_player)) return; |
3776 if (IsHumanPlayer(_current_player)) return; |
3777 } |
3777 } |
3778 |
3778 |
3779 if (p->bankrupt_asked == 255) return; |
3779 if (p->bankrupt_asked == 255) return; |
3780 |
3780 |
3781 { |
3781 { |
3807 if (best_pl->index == _local_player) { |
3807 if (best_pl->index == _local_player) { |
3808 p->bankrupt_timeout = 4440; |
3808 p->bankrupt_timeout = 4440; |
3809 ShowBuyCompanyDialog(_current_player); |
3809 ShowBuyCompanyDialog(_current_player); |
3810 return; |
3810 return; |
3811 } |
3811 } |
3812 if (IS_HUMAN_PLAYER(best_pl->index)) return; |
3812 if (IsHumanPlayer(best_pl->index)) return; |
3813 |
3813 |
3814 // Too little money for computer to buy it? |
3814 // Too little money for computer to buy it? |
3815 if (best_pl->player_money >> 1 >= p->bankrupt_value) { |
3815 if (best_pl->player_money >> 1 >= p->bankrupt_value) { |
3816 // Computer wants to buy it. |
3816 // Computer wants to buy it. |
3817 old_p = _current_player; |
3817 old_p = _current_player; |
3864 // to the patch-setting |
3864 // to the patch-setting |
3865 // Also, it takes into account the setting if the service-interval is in days |
3865 // Also, it takes into account the setting if the service-interval is in days |
3866 // or in % |
3866 // or in % |
3867 _ai_service_interval = _patches.servint_ispercent?80:180; |
3867 _ai_service_interval = _patches.servint_ispercent?80:180; |
3868 |
3868 |
3869 if (IS_HUMAN_PLAYER(_current_player)) return; |
3869 if (IsHumanPlayer(_current_player)) return; |
3870 |
3870 |
3871 AiAdjustLoan(p); |
3871 AiAdjustLoan(p); |
3872 AiBuildCompanyHQ(p); |
3872 AiBuildCompanyHQ(p); |
3873 |
3873 |
3874 #if 0 |
3874 #if 0 |