# ai_industrytype.hpp

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 AI_INDUSTRYTYPE_HPP
    00013 #define AI_INDUSTRYTYPE_HPP
    00014
    00015 #include "ai_list.hpp"
    00016
    00020 class AIIndustryType : public AIObject {
    00021 public:
    00023   static const char *GetClassName() { return "AIIndustryType"; }
    00024
    00028   enum SpecialIndustryType {
    00029     INDUSTRYTYPE_UNKNOWN = 0xFE,
    00030     INDUSTRYTYPE_TOWN    = 0xFF,
    00031   };
    00032
    00038   static bool IsValidIndustryType(IndustryType industry_type);
    00039
    00046   static char *GetName(IndustryType industry_type);
    00047
    00056   static AIList *GetProducedCargo(IndustryType industry_type);
    00057
    00066   static AIList *GetAcceptedCargo(IndustryType industry_type);
    00067
    00074   static bool IsRawIndustry(IndustryType industry_type);
    00075
    00082   static bool ProductionCanIncrease(IndustryType industry_type);
    00083
    00090   static Money GetConstructionCost(IndustryType industry_type);
    00091
    00099   static bool CanBuildIndustry(IndustryType industry_type);
    00100
    00109   static bool CanProspectIndustry(IndustryType industry_type);
    00110
    00118   static bool BuildIndustry(IndustryType industry_type, TileIndex tile);
    00119
    00129   static bool ProspectIndustry(IndustryType industry_type);
    00130
    00137   static bool IsBuiltOnWater(IndustryType industry_type);
    00138
    00145   static bool HasHeliport(IndustryType industry_type);
    00146
    00153   static bool HasDock(IndustryType industry_type);
    00154 };
    00155
    00156 #endif /* AI_INDUSTRYTYPE_HPP */