diff -r edaee7e60215 src/ai/api/ai_order.cpp --- a/src/ai/api/ai_order.cpp Wed Aug 31 17:45:24 2011 +0000 +++ b/src/ai/api/ai_order.cpp Wed Aug 31 20:42:36 2011 +0200 @@ -176,6 +176,7 @@ case OC_RELIABILITY: case OC_MAX_SPEED: case OC_AGE: + case OC_REMAINING_LIFETIME: return compare >= CF_EQUALS && compare <= CF_MORE_EQUALS; case OC_REQUIRES_SERVICE: diff -r edaee7e60215 src/ai/api/ai_order.hpp --- a/src/ai/api/ai_order.hpp Wed Aug 31 17:45:24 2011 +0000 +++ b/src/ai/api/ai_order.hpp Wed Aug 31 20:42:36 2011 +0200 @@ -93,6 +93,7 @@ OC_AGE, ///< Skip based on the age, value is in years. OC_REQUIRES_SERVICE, ///< Skip when the vehicle requires service, no value. OC_UNCONDITIONALLY, ///< Always skip, no compare function, no value. + OC_REMAINING_LIFETIME, ///< Skip based on the remaining lifetime OC_INVALID = -1, ///< An invalid condition, do not use. }; diff -r edaee7e60215 src/ai/api/ai_order.hpp.sq --- a/src/ai/api/ai_order.hpp.sq Wed Aug 31 17:45:24 2011 +0000 +++ b/src/ai/api/ai_order.hpp.sq Wed Aug 31 20:42:36 2011 +0200 @@ -66,6 +66,7 @@ SQAIOrder.DefSQConst(engine, AIOrder::OC_AGE, "OC_AGE"); SQAIOrder.DefSQConst(engine, AIOrder::OC_REQUIRES_SERVICE, "OC_REQUIRES_SERVICE"); SQAIOrder.DefSQConst(engine, AIOrder::OC_UNCONDITIONALLY, "OC_UNCONDITIONALLY"); + SQAIOrder.DefSQConst(engine, AIOrder::OC_REMAINING_LIFETIME, "OC_REMAINING_LIFETIME"); SQAIOrder.DefSQConst(engine, AIOrder::OC_INVALID, "OC_INVALID"); SQAIOrder.DefSQConst(engine, AIOrder::CF_EQUALS, "CF_EQUALS"); SQAIOrder.DefSQConst(engine, AIOrder::CF_NOT_EQUALS, "CF_NOT_EQUALS");