cargodest_func.h

Go to the documentation of this file.
00001 /* $Id$ */
00002 
00003 /*
00004  * This file is part of OpenTTD.
00005  * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
00006  * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
00007  * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
00008  */
00009 
00012 #ifndef CARGODEST_FUNC_H
00013 #define CARGODEST_FUNC_H
00014 
00015 #include "cargodest_type.h"
00016 #include "cargo_type.h"
00017 #include "vehicle_type.h"
00018 #include "station_type.h"
00019 #include "order_type.h"
00020 
00021 bool CargoHasDestinations(CargoID cid);
00022 
00023 RouteLink *FindRouteLinkForCargo(Station *st, CargoID cid, const struct CargoPacket *cp, StationID *next_unload, OrderID order = INVALID_ORDER, bool *found = NULL);
00024 bool MoveCargoWithDestinationToStation(CargoID cid, uint *amount, SourceType source_type, SourceID source_id, const StationList *all_stations, TileIndex src_tile);
00025 
00026 void UpdateVehicleRouteLinks(const Vehicle *v, StationID arrived_at);
00027 void PrefillRouteLinks(const Vehicle *v);
00028 void InvalidateStationRouteLinks(Station *station);
00029 void InvalidateOrderRouteLinks(OrderID order);
00030 void AgeRouteLinks(Station *st);
00031 
00032 void RebuildCargoLinkCounts();
00033 void UpdateCargoLinks();
00034 
00035 #endif /* CARGODEST_FUNC_H */

Generated on Fri Jun 3 05:18:49 2011 for OpenTTD by  doxygen 1.6.1