@@ -46,49 +46,49 @@ public:
/** Do not stop at the stations that are passed when going to the destination. Only for trains and road vehicles. */
AIOF_NON_STOP_INTERMEDIATE = 1 << 0,
/** Do not stop at the destionation station. Only for trains and road vehicles. */
AIOF_NON_STOP_DESTINATION = 1 << 1,
/** Always unload the vehicle; only for stations. Cannot be set when AIOF_TRANSFER or AIOF_NO_UNLOAD is set. */
AIOF_UNLOAD = 1 << 2,
/** Transfer instead of deliver the goods; only for stations. Cannot be set when AIOF_UNLOAD or AIOF_NO_UNLOAD is set. */
AIOF_TRANSFER = 1 << 3,
/** Never unload the vehicle; only for stations. Cannot be set when AIOF_UNLOAD, AIOF_TRANSFER or AIOF_NO_LOAD is set. */
AIOF_NO_UNLOAD = 1 << 4,
/** Wait till the vehicle is fully loaded; only for stations. Cannot be set when AIOF_NO_LOAD is set. */
AIOF_FULL_LOAD = 2 << 5,
/** Wait till at least one cargo of the vehicle is fully loaded; only for stations. Cannot be set when AIOF_NO_LOAD is set. */
AIOF_FULL_LOAD_ANY = 3 << 5,
/** Do not load any cargo; only for stations. Cannot be set when AIOF_NO_UNLOAD, AIOF_FULL_LOAD or AIOF_FULL_LOAD_ANY is set. */
AIOF_NO_LOAD = 1 << 7,
/** Service the vehicle when needed, otherwise skip this order; only for depots. */
AIOF_SERVICE_IF_NEEDED = 1 << 2,
/** Stop in the depot instead of only go there for servicing; only for depots. */
AIOF_STOP_IN_DEPOT = 1 << 3,
/** Go to nearest depot. */
AIOF_GOTO_NEAREST_DEPOT = 1 << 4,
AIOF_GOTO_NEAREST_DEPOT = 1 << 8,
/** All flags related to non-stop settings. */
AIOF_NON_STOP_FLAGS = AIOF_NON_STOP_INTERMEDIATE | AIOF_NON_STOP_DESTINATION,
/** All flags related to unloading. */
AIOF_UNLOAD_FLAGS = AIOF_TRANSFER | AIOF_UNLOAD | AIOF_NO_UNLOAD,
/** All flags related to loading. */
AIOF_LOAD_FLAGS = AIOF_FULL_LOAD | AIOF_FULL_LOAD_ANY | AIOF_NO_LOAD,
/** All flags related to depots. */
AIOF_DEPOT_FLAGS = AIOF_SERVICE_IF_NEEDED | AIOF_STOP_IN_DEPOT | AIOF_GOTO_NEAREST_DEPOT,
/** For marking invalid order flags */
AIOF_INVALID = 0xFFFF,
};
/**
* All conditions a conditional order can depend on.
*/
enum OrderCondition {
/* Order _is_ important, as it's based on OrderConditionVariable in order_type.h. */
OC_LOAD_PERCENTAGE, //!< Skip based on the amount of load, value is in tons.
OC_RELIABILITY, //!< Skip based on the reliability, value is percent (0..100).
OC_MAX_SPEED, //!< Skip based on the maximum speed, value is in OpenTTD's internal speed unit, see AIEngine::GetMaxSpeed.
OC_AGE, //!< Skip based on the age, value is in years.
OC_REQUIRES_SERVICE, //!< Skip when the vehicle requires service, no value.
Status change: