OpenTTD Source 20260206-master-g4d4e37dbf1
InvokeGrfChangeInfoHandler Struct Reference

Helper class to invoke a GrfChangeInfoHandler. More...

Public Types

using Invoker = ChangeInfoResult(*)(uint first, uint last, int prop, ByteReader &buf, GrfLoadingStage stage)

Static Public Member Functions

template<GrfSpecFeature TFeature>
static ChangeInfoResult Invoke (uint first, uint last, int prop, ByteReader &buf, GrfLoadingStage stage)
static ChangeInfoResult Invoke (GrfSpecFeature feature, uint first, uint last, int prop, ByteReader &buf, GrfLoadingStage stage)

Static Public Attributes

static constexpr Invoker funcs []

Detailed Description

Helper class to invoke a GrfChangeInfoHandler.

Definition at line 142 of file newgrf_act0.cpp.

Member Typedef Documentation

◆ Invoker

using InvokeGrfChangeInfoHandler::Invoker = ChangeInfoResult(*)(uint first, uint last, int prop, ByteReader &buf, GrfLoadingStage stage)

Definition at line 153 of file newgrf_act0.cpp.

Member Function Documentation

◆ Invoke() [1/2]

ChangeInfoResult InvokeGrfChangeInfoHandler::Invoke ( GrfSpecFeature feature,
uint first,
uint last,
int prop,
ByteReader & buf,
GrfLoadingStage stage )
inlinestatic

Definition at line 163 of file newgrf_act0.cpp.

◆ Invoke() [2/2]

template<GrfSpecFeature TFeature>
ChangeInfoResult InvokeGrfChangeInfoHandler::Invoke ( uint first,
uint last,
int prop,
ByteReader & buf,
GrfLoadingStage stage )
inlinestatic

Definition at line 144 of file newgrf_act0.cpp.

Field Documentation

◆ funcs

Invoker InvokeGrfChangeInfoHandler::funcs[]
staticconstexpr
Initial value:
{
Invoke<GSF_TRAINS>, Invoke<GSF_ROADVEHICLES>, Invoke<GSF_SHIPS>, Invoke<GSF_AIRCRAFT>,
Invoke<GSF_STATIONS>, Invoke<GSF_CANALS>, Invoke<GSF_BRIDGES>, Invoke<GSF_HOUSES>,
Invoke<GSF_GLOBALVAR>, Invoke<GSF_INDUSTRYTILES>, Invoke<GSF_INDUSTRIES>, Invoke<GSF_CARGOES>,
Invoke<GSF_SOUNDFX>, Invoke<GSF_AIRPORTS>, nullptr , Invoke<GSF_OBJECTS>,
Invoke<GSF_RAILTYPES>, Invoke<GSF_AIRPORTTILES>, Invoke<GSF_ROADTYPES>, Invoke<GSF_TRAMTYPES>,
Invoke<GSF_ROADSTOPS>, Invoke<GSF_BADGES>,
}

Definition at line 154 of file newgrf_act0.cpp.


The documentation for this struct was generated from the following file: