openttd updated to 1.5.0-beta2

--HG--
branch : openttd
This commit is contained in:
Pavel Stupnikov
2015-03-01 00:30:53 +03:00
parent 0abb47ce90
commit d201932121
682 changed files with 26103 additions and 16553 deletions
+11 -8
View File
@@ -1,4 +1,4 @@
/* $Id: oldloader_sl.cpp 25508 2013-06-29 09:47:18Z rubidium $ */
/* $Id: oldloader_sl.cpp 26878 2014-09-21 11:23:33Z rubidium $ */
/*
* This file is part of OpenTTD.
@@ -27,6 +27,7 @@
#include "../effectvehicle_base.h"
#include "../engine_func.h"
#include "../company_base.h"
#include "../disaster_vehicle.h"
#include "saveload_internal.h"
#include "oldloader.h"
@@ -34,6 +35,8 @@
#include "../table/engines.h"
#include "../table/townname.h"
#include "../safeguards.h"
static bool _read_ttdpatch_flags; ///< Have we (tried to) read TTDPatch extra flags?
static uint16 _old_extra_chunk_nums; ///< Number of extra TTDPatch chunks
static byte _old_vehicle_multiplier; ///< TTDPatch vehicle multiplier
@@ -708,8 +711,8 @@ static bool LoadOldGood(LoadgameState *ls, int num)
if (!LoadChunk(ls, ge, goods_chunk)) return false;
SB(ge->acceptance_pickup, GoodsEntry::GES_ACCEPTANCE, 1, HasBit(_waiting_acceptance, 15));
SB(ge->acceptance_pickup, GoodsEntry::GES_PICKUP, 1, _cargo_source != 0xFF);
SB(ge->status, GoodsEntry::GES_ACCEPTANCE, 1, HasBit(_waiting_acceptance, 15));
SB(ge->status, GoodsEntry::GES_RATING, 1, _cargo_source != 0xFF);
if (GB(_waiting_acceptance, 0, 12) != 0 && CargoPacket::CanAllocateItem()) {
ge->cargo.Append(new CargoPacket(GB(_waiting_acceptance, 0, 12), _cargo_days, (_cargo_source == 0xFF) ? INVALID_STATION : _cargo_source, 0, 0),
INVALID_STATION);
@@ -1492,10 +1495,10 @@ static bool LoadOldMapPart1(LoadgameState *ls, int num)
}
for (uint i = 0; i < OLD_MAP_SIZE / 4; i++) {
byte b = ReadByte(ls);
_m[i * 4 + 0].m6 = GB(b, 0, 2);
_m[i * 4 + 1].m6 = GB(b, 2, 2);
_m[i * 4 + 2].m6 = GB(b, 4, 2);
_m[i * 4 + 3].m6 = GB(b, 6, 2);
_me[i * 4 + 0].m6 = GB(b, 0, 2);
_me[i * 4 + 1].m6 = GB(b, 2, 2);
_me[i * 4 + 2].m6 = GB(b, 4, 2);
_me[i * 4 + 3].m6 = GB(b, 6, 2);
}
}
@@ -1507,7 +1510,7 @@ static bool LoadOldMapPart2(LoadgameState *ls, int num)
uint i;
for (i = 0; i < OLD_MAP_SIZE; i++) {
_m[i].type_height = ReadByte(ls);
_m[i].type = ReadByte(ls);
}
for (i = 0; i < OLD_MAP_SIZE; i++) {
_m[i].m5 = ReadByte(ls);