30 GrfMsg(1,
"CanalChangeInfo: Canal feature 0x{:02X} is invalid, max {}, ignoring", last,
CanalFeature::End);
34 for (uint
id = first;
id < last; ++id) {
Class to read from a NewGRF file.
uint8_t ReadByte()
Read a single byte (8 bits).
Functions related to debugging.
constexpr std::underlying_type_t< enum_type > to_underlying(enum_type e)
Implementation of std::to_underlying (from C++23).
EnumBitSet< CanalFeatureFlag, uint8_t > CanalFeatureFlags
CanalFeatureFlag bitmask.
CanalFeature
List of different canal 'features'.
static ChangeInfoResult CanalChangeInfo(uint first, uint last, int prop, ByteReader &buf)
Define properties for water features.
NewGRF buffer reader definition.
EnumBitSet< CanalCallbackMask, uint8_t > CanalCallbackMasks
Bitset of CanalCallbackMask elements.
NewGRF internal processing state.
ChangeInfoResult
Possible return values for the GrfChangeInfoHandler functions.
@ Success
Variable was parsed and read.
@ Unhandled
Variable was parsed but unread.
@ Unknown
Variable is unknown.
@ InvalidId
Attempt to modify an invalid ID.
A number of safeguards to prevent using unsafe methods.
Definition of base types and functions in a cross-platform compatible way.
Canal properties local to the NewGRF.
CanalCallbackMasks callback_mask
Bitmask of canal callbacks that have to be called.
CanalFeatureFlags flags
Flags controlling display.
static ChangeInfoResult Reserve(uint first, uint last, int prop, ByteReader &buf)
Implementation of the GrfLoadingStage::Reserve stage of this feature.
static ChangeInfoResult Activation(uint first, uint last, int prop, ByteReader &buf)
Implementation of the GrfLoadingStage::Activation stage of this feature.