865 |
865 |
866 _current_player_id = (PlayerID)num; |
866 _current_player_id = (PlayerID)num; |
867 |
867 |
868 if (!LoadChunk(ls, p, player_chunk)) return false; |
868 if (!LoadChunk(ls, p, player_chunk)) return false; |
869 |
869 |
|
870 if (_old_string_id == 0) { |
|
871 p->is_active = false; |
|
872 return true; |
|
873 } |
|
874 |
870 p->name_1 = RemapOldStringID(_old_string_id); |
875 p->name_1 = RemapOldStringID(_old_string_id); |
871 p->president_name_1 = RemapOldStringID(_old_string_id_2); |
876 p->president_name_1 = RemapOldStringID(_old_string_id_2); |
872 p->player_money = p->player_money; |
|
873 |
877 |
874 if (num == 0) { |
878 if (num == 0) { |
875 /* If the first player has no name, make sure we call it UNNAMED */ |
879 /* If the first player has no name, make sure we call it UNNAMED */ |
876 if (p->name_1 == 0) |
880 if (p->name_1 == 0) |
877 p->name_1 = STR_SV_UNNAMED; |
881 p->name_1 = STR_SV_UNNAMED; |
1409 OCL_VAR ( OC_FILE_I16 | OC_VAR_I32, 1, &_saved_scrollpos_y ), |
1413 OCL_VAR ( OC_FILE_I16 | OC_VAR_I32, 1, &_saved_scrollpos_y ), |
1410 OCL_VAR ( OC_FILE_U16 | OC_VAR_U8, 1, &_saved_scrollpos_zoom ), |
1414 OCL_VAR ( OC_FILE_U16 | OC_VAR_U8, 1, &_saved_scrollpos_zoom ), |
1411 |
1415 |
1412 OCL_VAR ( OC_FILE_U32 | OC_VAR_I64, 1, &_economy.max_loan ), |
1416 OCL_VAR ( OC_FILE_U32 | OC_VAR_I64, 1, &_economy.max_loan ), |
1413 OCL_VAR ( OC_FILE_U32 | OC_VAR_I64, 1, &_economy.max_loan_unround ), |
1417 OCL_VAR ( OC_FILE_U32 | OC_VAR_I64, 1, &_economy.max_loan_unround ), |
1414 OCL_VAR ( OC_FILE_U16 | OC_VAR_U32, 1, &_economy.fluct ), |
1418 OCL_VAR ( OC_INT16, 1, &_economy.fluct ), |
1415 |
1419 |
1416 OCL_VAR ( OC_UINT16, 1, &_disaster_delay ), |
1420 OCL_VAR ( OC_UINT16, 1, &_disaster_delay ), |
1417 |
1421 |
1418 OCL_NULL( 144 ), ///< cargo-stuff, calculated in InitializeLandscapeVariables |
1422 OCL_NULL( 144 ), ///< cargo-stuff, calculated in InitializeLandscapeVariables |
1419 |
1423 |