Bump savegame for object ground types
This commit is contained in:
@@ -68,6 +68,7 @@
|
||||
#include "../company_func.h"
|
||||
#include "../infrastructure_func.h"
|
||||
#include "../event_logs.h"
|
||||
#include "../newgrf_object.h"
|
||||
|
||||
|
||||
#include "saveload_internal.h"
|
||||
@@ -3979,6 +3980,17 @@ bool AfterLoadGame()
|
||||
}
|
||||
}
|
||||
|
||||
if (SlXvIsFeatureMissing(XSLFI_OBJECT_GROUND_TYPES)) {
|
||||
for (TileIndex t = 0; t < map_size; t++) {
|
||||
if (IsTileType(t, MP_OBJECT)) {
|
||||
_m[t].m4 = 0;
|
||||
ObjectType type = GetObjectType(t);
|
||||
extern void SetShouldObjectHaveNoFoundation(TileIndex tile, Slope tileh, ObjectType type, const ObjectSpec *spec);
|
||||
SetShouldObjectHaveNoFoundation(t, SLOPE_ELEVATED, type, ObjectSpec::Get(type));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
InitializeRoadGUI();
|
||||
|
||||
/* This needs to be done after conversion. */
|
||||
|
@@ -159,6 +159,7 @@ const SlxiSubChunkInfo _sl_xv_sub_chunk_infos[] = {
|
||||
{ XSLFI_DEPOT_ORDER_EXTRA_FLAGS,XSCF_IGNORABLE_UNKNOWN, 1, 1, "depot_order_extra_flags", nullptr, nullptr, nullptr },
|
||||
{ XSLFI_EXTRA_SIGNAL_TYPES, XSCF_NULL, 1, 1, "extra_signal_types", nullptr, nullptr, nullptr },
|
||||
{ XSLFI_BANKRUPTCY_EXTRA, XSCF_NULL, 1, 1, "bankruptcy_extra", nullptr, nullptr, nullptr },
|
||||
{ XSLFI_OBJECT_GROUND_TYPES, XSCF_NULL, 1, 1, "object_ground_types", nullptr, nullptr, nullptr },
|
||||
{ XSLFI_SCRIPT_INT64, XSCF_NULL, 1, 1, "script_int64", nullptr, nullptr, nullptr },
|
||||
{ XSLFI_NULL, XSCF_NULL, 0, 0, nullptr, nullptr, nullptr, nullptr },// This is the end marker
|
||||
};
|
||||
|
@@ -113,6 +113,8 @@ enum SlXvFeatureIndex {
|
||||
XSLFI_DEPOT_ORDER_EXTRA_FLAGS, ///< Depot order extra flags
|
||||
XSLFI_EXTRA_SIGNAL_TYPES, ///< Extra signal types
|
||||
XSLFI_BANKRUPTCY_EXTRA, ///< Extra company bankruptcy fields
|
||||
XSLFI_OBJECT_GROUND_TYPES, ///< Object ground types
|
||||
|
||||
XSLFI_SCRIPT_INT64, ///< See: SLV_SCRIPT_INT64
|
||||
|
||||
XSLFI_RIFF_HEADER_60_BIT, ///< Size field in RIFF chunk header is 60 bit
|
||||
|
Reference in New Issue
Block a user