Simutrans-Squirrel-API
Public Member Functions | List of all members
factory_desc_x Class Reference
Inheritance diagram for factory_desc_x:
obj_desc_x extend_get

Public Member Functions

building_desc_x get_building_desc ()
 
array< factory_slot_information_xget_inputs ()
 
table< factory_desc_xget_list ()
 
string get_name ()
 
array< factory_slot_information_xget_outputs ()
 
integer get_productivity_base ()
 
integer get_productivity_range ()
 
bool is_electricity_producer ()
 
- Public Member Functions inherited from obj_desc_x
string get_name ()
 
bool is_equal (obj_desc_x other)
 
bool is_valid ()
 

Detailed Description

Object descriptors for factories.

Definition at line 267 of file api_obj_desc.cc.

Member Function Documentation

◆ get_building_desc()

building_desc_x factory_desc_x::get_building_desc ( )

Descriptor of associated building.

◆ get_inputs()

array<factory_slot_information_x> factory_desc_x::get_inputs ( )

Returns array with information about input goods

◆ get_list()

table<factory_desc_x> factory_desc_x::get_list ( )

Returns table with all factory types. The factory names are used as table keys.

◆ get_name()

string factory_desc_x::get_name ( )
Returns
name

◆ get_outputs()

array<factory_slot_information_x> factory_desc_x::get_outputs ( )

Returns array with information about input goods

◆ get_productivity_base()

integer factory_desc_x::get_productivity_base ( )

Initial production of a factory is get_productivity_base() + rand( get_productivity_range() ).

Returns
base production

◆ get_productivity_range()

integer factory_desc_x::get_productivity_range ( )
Returns
base production variable range

◆ is_electricity_producer()

bool factory_desc_x::is_electricity_producer ( )
Returns
true if this factory produces electricity

The documentation for this class was generated from the following file: