Mercurial > hg > openttd
changeset 9620:3eb9ab10787d draft
(svn r13676) -Fix [FS#2126]: inactive companies from old (TTD) saves could be marked active in some cases, which then loads garbage in their statistics and such.
author | rubidium <rubidium@openttd.org> |
---|---|
date | Fri, 04 Jul 2008 19:00:11 +0000 |
parents | d287838c713c |
children | 4a11147d389c |
files | src/oldloader.cpp |
diffstat | 1 files changed, 5 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/oldloader.cpp +++ b/src/oldloader.cpp @@ -1007,9 +1007,13 @@ if (!LoadChunk(ls, p, player_chunk)) return false; + if (_old_string_id == 0) { + p->is_active = false; + return true; + } + p->name_1 = RemapOldStringID(_old_string_id); p->president_name_1 = RemapOldStringID(_old_string_id_2); - p->player_money = p->player_money; _players_ai[_current_player_id].tick = ai_tick; if (num == 0) {