OpenTTD Source 20260711-master-g3fb3006dff
cargomonitor_sl.cpp File Reference

Code handling saving and loading of Cargo monitoring. More...

#include "../stdafx.h"
#include "saveload.h"
#include "compat/cargomonitor_sl_compat.h"
#include "../cargomonitor.h"
#include "../safeguards.h"

Go to the source code of this file.

Data Structures

struct  TempStorage
 Temporary storage of cargo monitoring data for loading or saving it. More...
struct  CMDLChunkHandler
 _cargo_deliveries monitoring map. More...
struct  CMPUChunkHandler
 _cargo_pickups monitoring map. More...

Functions

static CargoMonitorID FixupCargoMonitor (CargoMonitorID number)
const ChunkHandlerTable _cargomonitor_chunk_handlers (cargomonitor_chunk_handlers)

Variables

static const SaveLoad _cargomonitor_pair_desc []
 Description of the TempStorage structure for the purpose of load and save.
static const CMDLChunkHandler CMDL
 Chunk definition of the cargomonitoring maps.
static const CMPUChunkHandler CMPU
static const ChunkHandlerRef cargomonitor_chunk_handlers []

Detailed Description

Code handling saving and loading of Cargo monitoring.

Definition in file cargomonitor_sl.cpp.

Function Documentation

◆ FixupCargoMonitor()

CargoMonitorID FixupCargoMonitor ( CargoMonitorID number)
static

Definition at line 31 of file cargomonitor_sl.cpp.

Variable Documentation

◆ _cargomonitor_pair_desc

const SaveLoad _cargomonitor_pair_desc[]
static
Initial value:
= {
}
#define SLE_VAR(base, variable, type)
Storage of a variable in every version of a savegame.
Definition saveload.h:1017
Temporary storage of cargo monitoring data for loading or saving it.
static constexpr VarType U32
Store a 32 bits unsigned int.
Definition saveload.h:756

Description of the TempStorage structure for the purpose of load and save.

Definition at line 26 of file cargomonitor_sl.cpp.

Referenced by CMDLChunkHandler::Load(), CMPUChunkHandler::Load(), CMDLChunkHandler::Save(), and CMPUChunkHandler::Save().

◆ cargomonitor_chunk_handlers

const ChunkHandlerRef cargomonitor_chunk_handlers[]
static
Initial value:
= {
CMPU,
}
static const CMDLChunkHandler CMDL
Chunk definition of the cargomonitoring maps.

Definition at line 135 of file cargomonitor_sl.cpp.

◆ CMDL

const CMDLChunkHandler CMDL
static

Chunk definition of the cargomonitoring maps.

Definition at line 133 of file cargomonitor_sl.cpp.

◆ CMPU

const CMPUChunkHandler CMPU
static

Definition at line 134 of file cargomonitor_sl.cpp.