1
0
Fork 0

Codechange: use 'using' over 'typedef'

pull/13397/head
Rubidium 2025-01-28 17:41:47 +01:00 committed by rubidium42
parent 9a21ca31f8
commit 1543b909dd
1 changed files with 19 additions and 19 deletions

View File

@ -108,24 +108,24 @@
#ifdef DOXYGEN_API #ifdef DOXYGEN_API
/* Define all types here, so they are added to the API docs. */ /* Define all types here, so they are added to the API docs. */
typedef uint BridgeType; ///< The ID of a bridge type. using BridgeType = uint32_t; ///< The ID of a bridge type.
typedef uint8_t CargoType; ///< The ID of a cargo type. using CargoType = uint8_t; ///< The ID of a cargo type.
typedef uint16_t EngineID; ///< The ID of an engine. using EngineID = uint16_t; ///< The ID of an engine.
typedef uint16_t GoalID; ///< The ID of a goal. using GoalID = uint16_t; ///< The ID of a goal.
typedef uint16_t GroupID; ///< The ID of a group. using GroupID = uint16_t; ///< The ID of a group.
typedef uint16_t IndustryID; ///< The ID of an industry. using IndustryID = uint16_t; ///< The ID of an industry.
typedef uint8_t IndustryType; ///< The ID of an industry-type. using IndustryType = uint8_t; ///< The ID of an industry-type.
typedef int64_t Money; ///< Money, stored in a 32bit/64bit safe way. For scripts money is always in pounds. using Money = int64_t; ///< Money, stored in a 32bit/64bit safe way. For scripts money is always in pounds.
typedef uint16_t ObjectType; ///< The ID of an object-type. using ObjectType = uint16_t; ///< The ID of an object-type.
typedef uint16_t SignID; ///< The ID of a sign. using SignID = uint16_t; ///< The ID of a sign.
typedef uint16_t StationID; ///< The ID of a station. using StationID = uint16_t; ///< The ID of a station.
typedef uint32_t StringID; ///< The ID of a string. using StringID = uint32_t; ///< The ID of a string.
typedef uint16_t SubsidyID; ///< The ID of a subsidy. using SubsidyID = uint16_t; ///< The ID of a subsidy.
typedef uint16_t StoryPageID; ///< The ID of a story page. using StoryPageID = uint16_t; ///< The ID of a story page.
typedef uint16_t StoryPageElementID; ///< The ID of a story page element. using StoryPageElementID = uint16_t; ///< The ID of a story page element.
typedef uint32_t TileIndex; ///< The ID of a map location. using TileIndex = uint32_t; ///< The ID of a map location.
typedef uint16_t TownID; ///< The ID of a town. using TownID = uint16_t; ///< The ID of a town.
typedef uint32_t VehicleID; ///< The ID of a vehicle. using VehicleID = uint32_t; ///< The ID of a vehicle.
#endif /* DOXYGEN_API */ #endif /* DOXYGEN_API */
/** /**
@ -133,6 +133,6 @@ typedef uint32_t VehicleID; ///< The ID of a vehicle.
* *
* Possible value are defined inside each API class in an ErrorMessages enum. * Possible value are defined inside each API class in an ErrorMessages enum.
*/ */
typedef uint ScriptErrorType; using ScriptErrorType = uint32_t;
#endif /* SCRIPT_TYPES_HPP */ #endif /* SCRIPT_TYPES_HPP */