MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / PackEngineNameDParam

Function PackEngineNameDParam

src/engine_type.h:239–242  ·  view source on GitHub ↗

Combine an engine ID and a name context to an engine name dparam. */

Source from the content-addressed store, hash-verified

237
238/** Combine an engine ID and a name context to an engine name dparam. */
239inline uint64_t PackEngineNameDParam(EngineID engine_id, EngineNameContext context, uint32_t extra_data = 0)
240{
241 return engine_id.base() | (static_cast<uint64_t>(context) << 32) | (static_cast<uint64_t>(extra_data) << 40);
242}
243
244static const uint MAX_LENGTH_ENGINE_NAME_CHARS = 32; ///< The maximum length of an engine name in characters including '\0'
245

Callers 12

DrawWidgetMethod · 0.85
DrawShipDetailsFunction · 0.85
DrawWidgetMethod · 0.85
DrawRoadVehDetailsFunction · 0.85
DrawAircraftDetailsFunction · 0.85
EngineNameSorterFunction · 0.85
DrawEngineListFunction · 0.85
FilterByTextMethod · 0.85
OnClickMethod · 0.85
NewVehicleAvailableFunction · 0.85
TrainDetailsInfoTabFunction · 0.85

Calls 1

baseMethod · 0.45

Tested by

no test coverage detected