OpenTTD
Functions | Variables
depot_sl.cpp File Reference

Code handling saving and loading of depots. More...

#include "../stdafx.h"
#include "../depot_base.h"
#include "../town.h"
#include "saveload.h"
#include "../safeguards.h"

Go to the source code of this file.

Functions

static void Save_DEPT ()
 
static void Load_DEPT ()
 
static void Ptrs_DEPT ()
 

Variables

static TownID _town_index
 
static const SaveLoad _depot_desc []
 
const ChunkHandler _depot_chunk_handlers []
 

Detailed Description

Code handling saving and loading of depots.

Definition in file depot_sl.cpp.

Variable Documentation

◆ _depot_chunk_handlers

const ChunkHandler _depot_chunk_handlers[]
Initial value:
= {
{ 'DEPT', Save_DEPT, Load_DEPT, Ptrs_DEPT, NULL, CH_ARRAY | CH_LAST},
}
Last chunk in this array.
Definition: saveload.h:104

◆ _depot_desc

const SaveLoad _depot_desc[]
static
Initial value:
= {
SLE_CONDVAR(Depot, xy, SLE_FILE_U16 | SLE_VAR_U32, 0, 5),
SLE_CONDVAR(Depot, xy, SLE_UINT32, 6, SL_MAX_VERSION),
SLEG_CONDVAR(_town_index, SLE_UINT16, 0, 140),
SLE_CONDVAR(Depot, town_cn, SLE_UINT16, 141, SL_MAX_VERSION),
SLE_CONDVAR(Depot, build_date, SLE_INT32, 142, SL_MAX_VERSION),
}
#define SLE_CONDSTR(base, variable, type, length, from, to)
Storage of a string in some savegame versions.
Definition: saveload.h:278
#define SLE_CONDREF(base, variable, type, from, to)
Storage of a reference in some savegame versions.
Definition: saveload.h:256
Load/save a reference to a town.
Definition: saveload.h:84
#define SLE_CONDVAR(base, variable, type, from, to)
Storage of a variable in some savegame versions.
Definition: saveload.h:246
#define SL_MAX_VERSION
Highest possible savegame version.
Definition: saveload.h:96
#define SLEG_CONDVAR(variable, type, from, to)
Storage of a global variable in some savegame versions.
Definition: saveload.h:373
#define SLE_STR(base, variable, type, length)
Storage of a string in every savegame version.
Definition: saveload.h:322

Definition at line 22 of file depot_sl.cpp.