Merge branch 'master' into jgrpp-beta

# Conflicts:
#	src/console_cmds.cpp
#	src/debug.cpp
#	src/lang/vietnamese.txt
#	src/network/core/address.cpp
#	src/network/core/address.h
#	src/network/core/config.h
#	src/network/core/os_abstraction.cpp
#	src/network/core/os_abstraction.h
#	src/network/core/tcp_listen.h
#	src/network/core/udp.cpp
#	src/network/core/udp.h
#	src/network/network.cpp
#	src/network/network_client.cpp
#	src/network/network_gamelist.cpp
#	src/network/network_server.cpp
#	src/network/network_udp.cpp
#	src/newgrf.cpp
#	src/openttd.cpp
#	src/saveload/saveload.h
#	src/settings.cpp
#	src/settings_table.cpp
#	src/settings_type.h
#	src/table/settings/network_settings.ini
This commit is contained in:
Jonathan G Rennison
2021-11-02 00:51:54 +00:00
124 changed files with 3050 additions and 1274 deletions

View File

@@ -39,7 +39,7 @@
#include "strings_func.h"
#include "date_func.h"
#include "string_func.h"
#include "network/network.h"
#include "network/core/config.h"
#include "smallmap_gui.h"
#include "genworld.h"
#include "error.h"
@@ -52,6 +52,7 @@
#include "table/build_industry.h"
#include "3rdparty/cpp-btree/btree_map.h"
#include <map>
#include "safeguards.h"
@@ -82,7 +83,6 @@ static uint32 _ttdpatch_flags[8];
GRFLoadedFeatures _loaded_newgrf_features;
static const uint MAX_SPRITEGROUP = UINT8_MAX; ///< Maximum GRF-local ID for a spritegroup.
static const uint MAX_GRF_COUNT = 300; ///< Maximum number of NewGRF files that could be loaded.
/** Base GRF ID for OpenTTD's base graphics GRFs. */
static const uint32 OPENTTD_GRAPHICS_BASE_GRF_ID = BSWAP32(0xFF4F5400);
@@ -10637,12 +10637,6 @@ void LoadNewGRF(uint load_index, uint num_baseset)
num_non_static++;
}
if (num_grfs >= MAX_GRF_COUNT) {
DEBUG(grf, 0, "'%s' is not loaded as the maximum number of file slots has been reached", c->filename);
c->status = GCS_DISABLED;
c->error = new GRFError(STR_NEWGRF_ERROR_MSG_FATAL, STR_NEWGRF_ERROR_TOO_MANY_NEWGRFS_LOADED);
continue;
}
num_grfs++;
LoadNewGRFFile(c, stage, subdir, false);