When clearing auto timetables, mark times as undefined rather than 0.

Fix unautomate timetable having reversed ctrl key behaviour,
update tooltip string with ctrl behaviour.
Minor comment/whitespace fixes.
This commit is contained in:
Jonathan G Rennison
2015-11-30 19:48:44 +00:00
parent a7e9c9ce65
commit d2b87485fb
4 changed files with 8 additions and 8 deletions

View File

@@ -612,7 +612,7 @@ struct TimetableWindow : Window {
case WID_VT_AUTOMATE: {
uint32 p2 = 0;
if (!HasBit(v->vehicle_flags, VF_AUTOMATE_TIMETABLE)) SetBit(p2, 0);
if (!_ctrl_pressed) SetBit(p2, 1);
if (_ctrl_pressed) SetBit(p2, 1);
DoCommandP(0, v->index, p2, CMD_AUTOMATE_TIMETABLE | CMD_MSG(STR_ERROR_CAN_T_TIMETABLE_VEHICLE));
break;
}