Files @ r18770:fe0f5aab3963
Branch filter:

Location: cpp/openttd-patchpack/source/src/script/api/game/game_industry.hpp.sq

truebrain
(svn r23628) -Add: ScriptSubsidy::Create, to create subsidies (GameScript only)
/* $Id$ */

/*
 * 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/>.
 */

/* THIS FILE IS AUTO-GENERATED; PLEASE DO NOT ALTER MANUALLY */

#include "../script_industry.hpp"
#include "../template/template_industry.hpp.sq"


template <> const char *GetClassName<ScriptIndustry, ST_GS>() { return "GSIndustry"; }

void SQGSIndustry_Register(Squirrel *engine)
{
	DefSQClass<ScriptIndustry, ST_GS> SQGSIndustry("GSIndustry");
	SQGSIndustry.PreRegister(engine);
	SQGSIndustry.AddConstructor<void (ScriptIndustry::*)(), 1>(engine, "x");

	SQGSIndustry.DefSQConst(engine, ScriptIndustry::CAS_NOT_ACCEPTED, "CAS_NOT_ACCEPTED");
	SQGSIndustry.DefSQConst(engine, ScriptIndustry::CAS_ACCEPTED,     "CAS_ACCEPTED");
	SQGSIndustry.DefSQConst(engine, ScriptIndustry::CAS_TEMP_REFUSED, "CAS_TEMP_REFUSED");

	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetIndustryCount,                  "GetIndustryCount",                  1, ".");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::IsValidIndustry,                   "IsValidIndustry",                   2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetIndustryID,                     "GetIndustryID",                     2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetName,                           "GetName",                           2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::IsCargoAccepted,                   "IsCargoAccepted",                   3, ".ii");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetStockpiledCargo,                "GetStockpiledCargo",                3, ".ii");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetLastMonthProduction,            "GetLastMonthProduction",            3, ".ii");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetLastMonthTransported,           "GetLastMonthTransported",           3, ".ii");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetLastMonthTransportedPercentage, "GetLastMonthTransportedPercentage", 3, ".ii");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetLocation,                       "GetLocation",                       2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetAmountOfStationsAround,         "GetAmountOfStationsAround",         2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetDistanceManhattanToTile,        "GetDistanceManhattanToTile",        3, ".ii");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetDistanceSquareToTile,           "GetDistanceSquareToTile",           3, ".ii");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::IsBuiltOnWater,                    "IsBuiltOnWater",                    2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::HasHeliport,                       "HasHeliport",                       2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetHeliportLocation,               "GetHeliportLocation",               2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::HasDock,                           "HasDock",                           2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetDockLocation,                   "GetDockLocation",                   2, ".i");
	SQGSIndustry.DefSQStaticMethod(engine, &ScriptIndustry::GetIndustryType,                   "GetIndustryType",                   2, ".i");

	SQGSIndustry.PostRegister(engine);
}