Add a "leave early" order timetable flag

Re-arrange timetable GUI slightly.
Add an "extra" drop-down item.
This commit is contained in:
Jonathan G Rennison
2018-08-13 01:40:17 +01:00
parent a5603b539f
commit 5344ec1931
10 changed files with 99 additions and 17 deletions

View File

@@ -432,6 +432,15 @@ public:
if (!this->IsType(OT_CONDITIONAL) && fixed != IsWaitFixed()) SB(this->GetXFlagsRef(), 1, 1, fixed ? 1 : 0);
}
/** Get the leave type */
inline OrderLeaveType GetLeaveType() const { return (OrderLeaveType)GB(this->GetXFlags(), 2, 2); }
/** Set the leave type */
inline void SetLeaveType(OrderLeaveType leave_type)
{
if (leave_type != this->GetLeaveType()) SB(this->GetXFlagsRef(), 2, 2, leave_type);
}
/**
* Get the occupancy value
* @return occupancy