Update to 1.10.0-beta2
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
/* $Id$ */
|
||||
|
||||
/*
|
||||
* This file is part of OpenTTD.
|
||||
* OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
|
||||
@@ -96,17 +94,16 @@ CompanyManagerFace ConvertFromOldCompanyManagerFace(uint32 face)
|
||||
void AfterLoadCompanyStats()
|
||||
{
|
||||
/* Reset infrastructure statistics to zero. */
|
||||
Company *c;
|
||||
FOR_ALL_COMPANIES(c) MemSetT(&c->infrastructure, 0);
|
||||
for (Company *c : Company::Iterate()) MemSetT(&c->infrastructure, 0);
|
||||
|
||||
/* Collect airport count. */
|
||||
Station *st;
|
||||
FOR_ALL_STATIONS(st) {
|
||||
for (const Station *st : Station::Iterate()) {
|
||||
if ((st->facilities & FACIL_AIRPORT) && Company::IsValidID(st->owner)) {
|
||||
Company::Get(st->owner)->infrastructure.airport++;
|
||||
}
|
||||
}
|
||||
|
||||
Company *c;
|
||||
for (TileIndex tile = 0; tile < MapSize(); tile++) {
|
||||
switch (GetTileType(tile)) {
|
||||
case MP_RAILWAY:
|
||||
@@ -488,8 +485,7 @@ static void SaveLoad_PLYR(Company *c)
|
||||
|
||||
static void Save_PLYR()
|
||||
{
|
||||
Company *c;
|
||||
FOR_ALL_COMPANIES(c) {
|
||||
for (Company *c : Company::Iterate()) {
|
||||
SlSetArrayIndex(c->index);
|
||||
SlAutolength((AutolengthProc*)SaveLoad_PLYR, c);
|
||||
}
|
||||
@@ -536,8 +532,7 @@ static void Check_PLYR()
|
||||
|
||||
static void Ptrs_PLYR()
|
||||
{
|
||||
Company *c;
|
||||
FOR_ALL_COMPANIES(c) {
|
||||
for (Company *c : Company::Iterate()) {
|
||||
SlObject(c, _company_settings_desc);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user