2005-07-24 14:12:37 +00:00
|
|
|
/* $Id$ */
|
|
|
|
|
2009-08-21 20:21:05 +00:00
|
|
|
/*
|
|
|
|
* This file is part of OpenTTD.
|
|
|
|
* 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.
|
|
|
|
* 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.
|
|
|
|
* 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/>.
|
|
|
|
*/
|
|
|
|
|
2008-05-06 15:11:33 +00:00
|
|
|
/** @file engine_func.h Functions related to engines. */
|
2007-02-23 18:55:07 +00:00
|
|
|
|
2004-08-09 17:04:08 +00:00
|
|
|
#ifndef ENGINE_H
|
|
|
|
#define ENGINE_H
|
|
|
|
|
2008-03-28 18:00:38 +00:00
|
|
|
#include "engine_type.h"
|
2010-01-15 16:41:15 +00:00
|
|
|
#include "vehicle_type.h"
|
|
|
|
#include "company_type.h"
|
2006-01-12 15:52:18 +00:00
|
|
|
|
2008-01-08 18:25:51 +00:00
|
|
|
void SetupEngines();
|
2007-03-07 11:47:46 +00:00
|
|
|
void StartupEngines();
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2008-04-29 21:31:29 +00:00
|
|
|
/* Original engine data counts and offsets */
|
|
|
|
extern const uint8 _engine_counts[4];
|
|
|
|
extern const uint8 _engine_offsets[4];
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2008-09-30 20:39:50 +00:00
|
|
|
bool IsEngineBuildable(EngineID engine, VehicleType type, CompanyID company);
|
2008-12-16 22:02:12 +00:00
|
|
|
bool IsEngineRefittable(EngineID engine);
|
2008-05-13 21:36:09 +00:00
|
|
|
void SetCachedEngineCounts();
|
2009-01-08 21:48:59 +00:00
|
|
|
void SetYearEngineAgingStops();
|
2009-01-23 02:35:17 +00:00
|
|
|
void StartupOneEngine(Engine *e, Date aging_date);
|
2004-08-09 17:04:08 +00:00
|
|
|
|
2009-10-06 19:52:38 +00:00
|
|
|
uint GetTotalCapacityOfArticulatedParts(EngineID engine);
|
2009-03-10 21:17:00 +00:00
|
|
|
|
2005-09-18 20:56:44 +00:00
|
|
|
#endif /* ENGINE_H */
|