Go to the documentation of this file.
10 #include "../stdafx.h"
11 #include "../newgrf_storage.h"
14 #include "../safeguards.h"
42 SlSetArrayIndex(ps->index);
#define SLE_CONDARR(base, variable, type, length, from, to)
Storage of an array in some savegame versions.
#define SLE_CONDVAR(base, variable, type, from, to)
Storage of a variable in some savegame versions.
@ CH_LAST
Last chunk in this array.
Handlers and description of chunk.
@ SLV_EXTEND_PERSISTENT_STORAGE
201 PR#6885 Extend NewGRF persistent storages.
Class for pooled persistent storage of data.
#define SLE_END()
End marker of a struct/class save or load.
const ChunkHandler _persistent_storage_chunk_handlers[]
Chunk handler for persistent storages.
static const SaveLoad _storage_desc[]
Description of the data to save and load in PersistentStorage.
void SlObject(void *object, const SaveLoad *sld)
Main SaveLoad function.
static void Load_PSAC()
Load persistent storage data.
@ SL_MAX_VERSION
Highest possible saveload version.
static Pool::IterateWrapper< Titem > Iterate(size_t from=0)
Returns an iterable ensemble of all valid Titem.
static void Save_PSAC()
Save persistent storage data.
static bool CanAllocateItem(size_t n=1)
Helper functions so we can use PoolItem::Function() instead of _poolitem_pool.Function()
int SlIterateArray()
Iterate through the elements of an array and read the whole thing.