Codechange: Un-bitstuff vehicle/engine commands.

This commit is contained in:
Michael Lutz
2021-11-05 23:55:23 +01:00
parent 2637c06f88
commit 21675ec7e2
25 changed files with 221 additions and 268 deletions

View File

@@ -61,14 +61,15 @@ enum VehiclePathFinders {
VPF_YAPF = 2, ///< Yet Another PathFinder
};
/** Flags to add to p1 for goto depot commands. */
enum DepotCommand {
DEPOT_SERVICE = (1U << 28), ///< The vehicle will leave the depot right after arrival (service only)
DEPOT_MASS_SEND = (1U << 29), ///< Tells that it's a mass send to depot command (type in VLW flag)
DEPOT_DONT_CANCEL = (1U << 30), ///< Don't cancel current goto depot command if any
DEPOT_LOCATE_HANGAR = (1U << 31), ///< Find another airport if the target one lacks a hangar
DEPOT_COMMAND_MASK = 0xFU << 28,
/** Flags for goto depot commands. */
enum class DepotCommand : byte {
None = 0, ///< No special flags.
Service = (1U << 0), ///< The vehicle will leave the depot right after arrival (service only)
MassSend = (1U << 1), ///< Tells that it's a mass send to depot command (type in VLW flag)
DontCancel = (1U << 2), ///< Don't cancel current goto depot command if any
LocateHangar = (1U << 3), ///< Find another airport if the target one lacks a hangar
};
DECLARE_ENUM_AS_BIT_SET(DepotCommand)
static const uint MAX_LENGTH_VEHICLE_NAME_CHARS = 32; ///< The maximum length of a vehicle name in characters including '\0'