summaryrefslogtreecommitdiff
path: root/src/order_backup.cpp
AgeCommit message (Collapse)Author
2019-03-21Fix #7391, 9b99b95: Don't invalidate go to depot orders of non-aircraft when ↵Michael Lutz
invalidating hangar orders that happen to share IDs. This was caused because hangars are referred to by station ID, which is not unique with respect to depot IDs.
2019-03-20Remove: ENABLE_NETWORK switchPatric Stout
This switch has been a pain for years. Often disabling broke compilation, as no developer compiles OpenTTD without, neither do any of our official binaries. Additionaly, it has grown so hugely in our codebase, that it clearly shows that the current solution was a poor one. 350+ instances of "#ifdef ENABLE_NETWORK" were in the code, of which only ~30 in the networking code itself. The rest were all around the code to do the right thing, from GUI to NewGRF. A more proper solution would be to stub all the functions, and make sure the rest of the code can simply assume network is available. This was also partially done, and most variables were correct if networking was disabled. Despite that, often the #ifdefs were still used. With the recent removal of DOS, there is also no platform anymore which we support where networking isn't working out-of-the-box. All in all, it is time to remove the ENABLE_NETWORK switch. No replacement is planned, but if you feel we really need this option, we welcome any Pull Request which implements this in a way that doesn't crawl through the code like this diff shows we used to.
2019-02-27Fix #6574: Remove go to hangar orders when rebuilding airportSamu
When replacing an airport with another, cancel current orders of type 'go to depot' from aircraft still heading to it if the rebuilt airport doesn't have a hangar (helicopter vs heliport), or if the airplane can't land on the rebuilt airport (airplane vs helistation). Removes 'go to hangar' orders from all aircraft when replacing an airport with hangar with another without hangar (heliport).
2014-04-23(svn r26482) -Codechange: add an include that allows us to undefine/redefine ↵rubidium
"unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values
2012-07-29(svn r24446) -Add [FS#5199]: Store more consist properties in order backups.frosch
2012-07-29(svn r24444) -Codechange: Base OrderBackup on BaseConsist.frosch
2011-12-09(svn r23464) -Fix [FS#4876]: clear the backed up orders of a removed station ↵rubidium
as well, otherwise one could create orders to a station that was never in the original backupped orders. For example a road vehicle trying to go to a buoy.
2011-11-12(svn r23199) -Fix [FS#4822]: oil rigs that "expired" did not get removed ↵rubidium
from the station list
2011-05-18(svn r22473) -Codechange: Automatic orders are better called implicit orders ↵planetmaker
as no real order influencing path finding is added
2011-05-02(svn r22410) -Document: some more bits ;)rubidium
2011-02-19(svn r22116) -Codechange: use PoolBase::Clean() at more placessmatz
2011-02-10(svn r22047) -Fix: selling a vehicle triggered the assert added in r22041yexo
2011-01-31(svn r21933) -Codechange: Split cur_order_index into cur_auto_order_index ↵frosch
and cur_real_order_index to keep track of the current real order in an unambiguous way. -Fix [FS#4440]: Automatic orders behave now stable wrt. service orders and are not added or removed depending on the need of servicing. -Fix: Various other issues with automatic orders, e.g. vehicles getting stuck with "no orders" when there are automatic orders at the end of the order list.
2011-01-18(svn r21846) -Codechange: move documentation towards the code to make it ↵rubidium
more likely to be updated [o-s].
2010-12-08(svn r21438) -Fix (r21424): fix triggered an assertion when the build did ↵rubidium
support networking
2010-12-07(svn r21424) -Fix: CMD_CLEAR_ORDER_BACKUP might not get executed when the ↵rubidium
user pressed the shift key
2010-08-26(svn r20632) -Cleanup: remove "a few" unneeded includes, and add them to ↵rubidium
some headers
2010-08-19(svn r20571) -Codechange: free/reserve some bits in the order commands to ↵rubidium
increase the vehicle pool limit
2010-08-18(svn r20547) -Change: the way order backups are performed. Now restoring an ↵rubidium
order doesn't require up to 765 commands.
2010-08-18(svn r20545) -Codechange: make sure an OrderBackup gets cleared when the ↵rubidium
depot it belongs to gets removed, the depot window gets closed or when another vehicle gets sold in a depot
2010-08-18(svn r20541) -Fix: when removing a vehicle update the "clone orders ↵rubidium
of"-vehicle of a backed up order, or remove it if there is no vehicle sharing orders with that vehicle.
2010-08-18(svn r20539) -Codechange: make order backups more self-contained.rubidium