Import more conditional orders patch
http://www.tt-forums.net/viewtopic.php?p=1033223#p1033223
This commit is contained in:

committed by
Jonathan G Rennison

parent
789266146f
commit
c757a97214
@@ -44,6 +44,8 @@ private:
|
||||
CargoID refit_cargo; ///< Refit CargoID
|
||||
byte refit_subtype; ///< Refit subtype
|
||||
|
||||
int8 jump_counter; ///< Counter for the 'jump xx% of times' option
|
||||
|
||||
public:
|
||||
Order *next; ///< Pointer to next order. If NULL, end of list
|
||||
|
||||
@@ -133,6 +135,14 @@ public:
|
||||
|
||||
void SetRefit(CargoID cargo, byte subtype = 0);
|
||||
|
||||
/**
|
||||
* Update the jump_counter of this order.
|
||||
* @param the jump chance in %.
|
||||
* @return whether to jump or not.
|
||||
* @pre IsType(OT_CONDITIONAL) && this->GetConditionVariable() == OCV_PERCENT.
|
||||
*/
|
||||
bool UpdateJumpCounter(uint8 percent);
|
||||
|
||||
/** How must the consist be loaded? */
|
||||
inline OrderLoadFlags GetLoadType() const { return (OrderLoadFlags)GB(this->flags, 4, 4); }
|
||||
/** How must the consist be unloaded? */
|
||||
|
Reference in New Issue
Block a user