OpenTTD Source
20240919-master-gdf0233f4c2
|
Go to the documentation of this file.
10 #include "../stdafx.h"
15 #include "../subsidy_base.h"
17 #include "../safeguards.h"
19 static const SaveLoad _subsidies_desc[] = {
40 SlSetArrayIndex(s->index);
@ SLV_5
5.0 1429 5.1 1440 5.2 1525 0.3.6
std::reference_wrapper< const ChunkHandler > ChunkHandlerRef
A reference to ChunkHandler.
@ SL_MIN_VERSION
First savegame version.
#define SLE_CONDVAR(base, variable, type, from, to)
Storage of a variable in some savegame versions.
Handlers and description of chunk.
@ SLV_CUSTOM_SUBSIDY_DURATION
292 PR#9081 Configurable subsidy duration.
Struct about subsidies, offered and awarded.
void Save() const override
Save the chunk.
const SaveLoadCompat _subsidies_sl_compat[]
Original field order for _subsidies_desc.
@ SL_MAX_VERSION
Highest possible saveload version.
void Load() const override
Load the chunk.
#define SLE_VAR(base, variable, type)
Storage of a variable in every version of a savegame.
static Pool::IterateWrapper< Titem > Iterate(size_t from=0)
Returns an iterable ensemble of all valid Titem.
std::span< const ChunkHandlerRef > ChunkHandlerTable
A table of ChunkHandler entries.
std::vector< SaveLoad > SlCompatTableHeader(const SaveLoadTable &slt, const SaveLoadCompatTable &slct)
Load a table header in a savegame compatible way.
void SlObject(void *object, const SaveLoadTable &slt)
Main SaveLoad function.
std::vector< SaveLoad > SlTableHeader(const SaveLoadTable &slt)
Save or Load a table header.
int SlIterateArray()
Iterate through the elements of an array and read the whole thing.