Esempio n. 1
0
from industry import IndustrySecondary, TileLocationChecks

# this industry overlaps with chemical plant somewhat, but blah blah blah

industry = IndustrySecondary(
    id="ammonia_plant",
    accept_cargos_with_input_ratios=[("NAPH", 8)],
    prod_cargo_types_with_output_ratios=[("NH3_", 3), ("UREA", 2),
                                         ("NHNO", 3)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="173",
    name="string(STR_IND_AMMONIA_PLANT)",
    nearby_station_name="string(STR_STATION_HEAVY_INDUSTRY_2)",
    fund_cost_multiplier="170",
    graphics_change_dates=[1952],
)

###industry.economy_variations['BETTER_LIVING_THROUGH_CHEMISTRY'].enabled = True

industry.add_tile(
    id="ammonia_plant_tile_1",
    animation_length=7,
    animation_looping=True,
    animation_speed=3,
    location_checks=TileLocationChecks(require_effectively_flat=True,
                                       disallow_industry_adjacent=True),
)

spriteset_ground = industry.add_spriteset(type="concrete", )
spriteset_ground_overlay = industry.add_spriteset(type="empty", )
Esempio n. 2
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(id='dairy',
                             processed_cargos_and_output_ratios=[('MNSP', 3), ('MILK', 5)],
                             combined_cargos_boost_prod=True,
                             prod_cargo_types=['FOOD'],
                             prob_in_game='3',
                             prob_random='5',
                             prod_multiplier='[0, 0]',
                             map_colour='169',
                             spec_flags='bitmask(IND_FLAG_MILITARY_HELICOPTER_CAN_EXPLODE)',
                             name='string(STR_IND_DAIRY)',
                             nearby_station_name='string(STR_STATION_DAIRY_LANE)',
                             fund_cost_multiplier='45')

industry.economy_variations['FIRS'].enabled = True
industry.economy_variations['FERNZ'].enabled = True
industry.economy_variations['FERNZ'].processed_cargos_and_output_ratios = [('SALT', 3), ('MILK', 5)]
industry.economy_variations['BASIC_TEMPERATE'].enabled = True
industry.economy_variations['BASIC_TEMPERATE'].processed_cargos_and_output_ratios = [('MILK', 6)]

# tile with animation for flag
industry.add_tile(id='dairy_tile_1',
                  animation_length=6,
                  animation_looping=True,
                  animation_speed=3,
                  location_checks=TileLocationChecks(require_effectively_flat=True,
                                                     disallow_industry_adjacent=True))
# tile with animation for smoke
industry.add_tile(id='dairy_tile_2',
                  animation_length=7 * 6,  # animation length should have a common factor for all tiles in industry
Esempio n. 3
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(id='blast_furnace',
                             processed_cargos_and_output_ratios=[('IORE', 3), ('COAL', 2), ('SCMT', 3)],
                             combined_cargos_boost_prod=True,
                             prod_cargo_types=['METL'],
                             prob_in_game='3',
                             prob_random='5',
                             prod_multiplier='[0, 0]',
                             map_colour='10',
                             spec_flags='bitmask()',
                             name='TTD_STR_INDUSTRY_NAME_STEEL_MILL',  # default to steel mill
                             nearby_station_name='string(STR_STATION_FURNACE)',
                             fund_cost_multiplier='190',
                             intro_year=1850)


industry.economy_variations['FIRS'].enabled = True
industry.economy_variations['FERNZ'].enabled = True
industry.economy_variations['FERNZ'].processed_cargos_and_output_ratios = [('ISND', 3), ('COAL', 2), ('SCMT', 3)]
industry.economy_variations['FERNZ'].prod_cargo_types = ['METL', 'SAND']
industry.economy_variations['BASIC_TEMPERATE'].enabled = True
industry.economy_variations['BASIC_TEMPERATE'].intro_year = 1800
industry.economy_variations['BASIC_TEMPERATE'].prod_cargo_types = ['STEL']
industry.economy_variations['STEELTOWN'].enabled = True
industry.economy_variations['STEELTOWN'].name = 'string(STR_IND_BLAST_FURNACE)'
industry.economy_variations['STEELTOWN'].processed_cargos_and_output_ratios = [('IORE', 3), ('COKE', 3), ('LIME', 2)]
industry.economy_variations['STEELTOWN'].prod_cargo_types = [('IRON', 6), ('SLAG', 2)]
industry.economy_variations['STEELTOWN'].prob_random = '3'

industry.add_tile(id='blast_furnace_tile_1',
Esempio n. 4
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id='metal_fabrication_plant',
    processed_cargos_and_output_ratios=[('METL', 6), ('RFPR', 2)],
    combined_cargos_boost_prod=True,
    prod_cargo_types=['BDMT'],
    prob_in_game='3',
    prob_random='5',
    prod_multiplier='[0, 0]',
    map_colour='160',
    name='string(STR_IND_METAL_FABRICATION_PLANT)',
    nearby_station_name='string(STR_STATION_HEAVY_INDUSTRY_2)',
    fund_cost_multiplier='120',
    intro_year=1832)

industry.economy_variations['FIRS'].enabled = True

industry.economy_variations['STEELTOWN'].enabled = True
industry.economy_variations[
    'STEELTOWN'].name = 'string(STR_IND_STEEL_FINISHING_PLANT)'
industry.economy_variations['STEELTOWN'].processed_cargos_and_output_ratios = [
    ('STEL', 4), ('ZINC', 2), ('ACID', 2)
]
industry.economy_variations['STEELTOWN'].prod_cargo_types = ['VBOD', 'PIPE']

industry.add_tile(id='metal_fabrication_plant_tile_1',
                  animation_length=71,
                  animation_looping=True,
                  animation_speed=2,
                  location_checks=TileLocationChecks(
Esempio n. 5
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id='food_processor',
    processed_cargos_and_output_ratios=[('MNSP', 2), ('BEAN', 6), ('FRUT', 6)],
    combined_cargos_boost_prod=True,
    prod_cargo_types=[('FOOD', 5), ('EOIL', 3)],
    prob_in_game='3',
    prob_random='5',
    prod_multiplier='[0, 0]',
    map_colour='181',
    name='TTD_STR_INDUSTRY_NAME_FOOD_PROCESSING_PLANT',
    nearby_station_name='string(STR_STATION_FOOD_CORPORATION)',
    fund_cost_multiplier='65')

industry.economy_variations['FIRS'].enabled = True
industry.economy_variations['MISTAH_KURTZ'].enabled = True
industry.economy_variations[
    'MISTAH_KURTZ'].processed_cargos_and_output_ratios = [('NUTS', 6),
                                                          ('FRUT', 6)]
industry.economy_variations['MISTAH_KURTZ'].prod_cargo_types = ['EOIL', 'FOOD']

industry.add_tile(id='food_processor_tile_1',
                  location_checks=TileLocationChecks(
                      require_effectively_flat=True,
                      disallow_industry_adjacent=True))

spriteset_ground = industry.add_spriteset(type='concrete')
spriteset_ground_overlay = industry.add_spriteset(type='empty')
spriteset_1 = industry.add_spriteset(sprites=[(10, 10, 64, 87, -31, -56)], )
spriteset_2 = industry.add_spriteset(sprites=[(80, 10, 64, 87, -31, -56)], )
Esempio n. 6
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="sugar_refinery",
    accept_cargos_with_input_ratios=[("MNSP", 3), ("SGBT", 5)],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[("FOOD", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="83",
    special_flags=["IND_FLAG_MILITARY_AIRPLANE_CAN_EXPLODE"],
    name="string(STR_IND_SUGAR_REFINERY)",
    nearby_station_name="string(STR_STATION_SUGAR_COMPANY)",
    fund_cost_multiplier="140",
)

# deliberately not in BLTC, requires sugar beet, which is too climate-specific for BLTC
# industry.economy_variations['BETTER_LIVING_THROUGH_CHEMISTRY'].enabled = True

industry.add_tile(
    id="sugar_refinery_tile_1",
    animation_length=7,
    animation_looping=True,
    animation_speed=3,
    location_checks=TileLocationChecks(
        require_effectively_flat=True, disallow_industry_adjacent=True
    ),
)

spriteset_ground = industry.add_spriteset(type="concrete")
spriteset_ground_overlay = industry.add_spriteset(type="empty")
Esempio n. 7
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="sawmill",
    accept_cargos_with_input_ratios=[("WOOD", 6)],
    prod_cargo_types_with_output_ratios=[("WDPR", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="194",
    name="TTD_STR_INDUSTRY_NAME_SAWMILL",
    nearby_station_name="string(STR_STATION_MILL)",
    fund_cost_multiplier="97",
)

industry.economy_variations["IN_A_HOT_COUNTRY"].enabled = True
industry.economy_variations["BASIC_ARCTIC"].enabled = True

industry.add_tile(
    id="sawmill_tile_1",
    location_checks=TileLocationChecks(disallow_industry_adjacent=True),
)

sprite_ground = industry.add_sprite(
    sprite_number="GROUNDTILE_MUD_TRACKS"  # ground tile same as overlay tile
)

spriteset_ground_overlay = industry.add_spriteset(type="empty")
sprite_hut_1 = industry.add_sprite(sprite_number="2069")
sprite_hut_2 = industry.add_sprite(sprite_number="2063")
sprite_logs_1 = industry.add_sprite(sprite_number="2066")
sprite_logs_2 = industry.add_sprite(sprite_number="2070")
Esempio n. 8
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="ferrochrome_smelter",
    accept_cargos_with_input_ratios=[("CHRO", 4), ("COAL", 4)],
    prod_cargo_types_with_output_ratios=[("FECR", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="19",
    special_flags=["IND_FLAG_MILITARY_HELICOPTER_CAN_EXPLODE"],
    name="string(STR_IND_FERROCHROME_SMELTER)",
    nearby_station_name="string(STR_STATION_SMELTER)",
    fund_cost_multiplier="120",
)

# industry.economy_variations['IN_A_HOT_COUNTRY'].enabled = True

industry.add_tile(
    id="ferrochrome_smelter_tile_1",
    animation_length=7,
    animation_looping=True,
    animation_speed=3,
    custom_animation_control={
        "macro": "random_first_frame",
        "animation_triggers": "bitmask(ANIM_TRIGGER_INDTILE_CONSTRUCTION_STATE)",
    },
    location_checks=TileLocationChecks(
        require_effectively_flat=True, disallow_industry_adjacent=True
    ),
)
Esempio n. 9
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="body_plant",
    accept_cargos_with_input_ratios=[("STSH", 4), ("COAT", 2), ("GLAS", 2)],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[("VBOD", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="194",
    name="string(STR_IND_BODY_PLANT)",
    nearby_station_name="string(STR_STATION_HEAVY_INDUSTRY_2)",
    fund_cost_multiplier="120",
    pollution_and_squalor_factor=1,
)

industry.economy_variations["STEELTOWN"].enabled = True
industry.economy_variations[
    "STEELTOWN"].prob_in_game = "0"  # do not build during gameplay

industry.add_tile(
    id="body_plant_tile_1",
    animation_length=71,
    animation_looping=True,
    animation_speed=2,
    location_checks=TileLocationChecks(require_effectively_flat=True,
                                       disallow_industry_adjacent=True),
)

spriteset_ground = industry.add_spriteset(type="concrete", )
spriteset_ground_overlay = industry.add_spriteset(type="empty")
Esempio n. 10
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="carbon_black_plant",
    # amount of output is unrealistic 8:8 but input is usually small, so give a decent amount out eh?
    accept_cargos_with_input_ratios=[("CTAR", 8)],
    prod_cargo_types_with_output_ratios=[("CBLK", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="178",
    special_flags=["IND_FLAG_MILITARY_HELICOPTER_CAN_EXPLODE"],
    # it's rare to force co-location of secondaries, but this one is near coke oven by design
    location_checks=dict(
        near_at_least_one_of_these_keystone_industries=[["coke_oven"], 72],
        same_type_distance=72,
    ),
    name="string(STR_IND_CARBON_BLACK_PLANT)",
    nearby_station_name="string(STR_STATION_SOOT_FURNACE)",
    fund_cost_multiplier="120",
    pollution_and_squalor_factor=2,
)

industry.economy_variations["STEELTOWN"].enabled = True
industry.economy_variations[
    "STEELTOWN"].prob_in_game = "0"  # do not build during gameplay

industry.add_tile(
    id="carbon_black_plant_tile_1",
    animation_length=7,
    animation_looping=True,
    animation_speed=3,
Esempio n. 11
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="dairy",
    accept_cargos_with_input_ratios=[("MILK", 6)],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[("FOOD", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="169",
    special_flags=["IND_FLAG_MILITARY_HELICOPTER_CAN_EXPLODE"],
    name="string(STR_IND_DAIRY)",
    nearby_station_name="string(STR_STATION_DAIRY_LANE)",
    fund_cost_multiplier="45",
)

industry.economy_variations["BASIC_TEMPERATE"].enabled = True
industry.economy_variations[
    "BASIC_TEMPERATE"].accept_cargos_with_input_ratios = [("MILK", 6)]

###industry.economy_variations['BETTER_LIVING_THROUGH_CHEMISTRY'].enabled = True
###industry.economy_variations['BETTER_LIVING_THROUGH_CHEMISTRY'].accept_cargos_with_input_ratios = [('MILK', 6), ('MNSP', 2)]

# tile with animation for flag
industry.add_tile(
    id="dairy_tile_1",
    animation_length=6,
    animation_looping=True,
    animation_speed=3,
    location_checks=TileLocationChecks(require_effectively_flat=True,
                                       disallow_industry_adjacent=True),
Esempio n. 12
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="wire_and_section_mill",
    accept_cargos_with_input_ratios=[("STCB", 4), ("ACID", 2), ("SOAP", 2)],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[
        ("STSE", 4),
        ("STWR", 3),
        ("ENSP", 1),
    ],  # balance is deliberate, steel sections need to feed wharf, vehicle chain is already well supplied
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="43",
    name="string(STR_IND_WIRE_AND_SECTION_MILL)",
    nearby_station_name="string(STR_STATION_ROD_MILL)",
    fund_cost_multiplier="120",
)

industry.economy_variations["STEELTOWN"].enabled = True
industry.economy_variations[
    "STEELTOWN"].prob_in_game = "0"  # do not build during gameplay

industry.add_tile(
    id="wire_and_section_mill_tile_1",
    animation_length=71,
    animation_looping=True,
    animation_speed=2,
    location_checks=TileLocationChecks(require_effectively_flat=True,
                                       disallow_industry_adjacent=True),
)
Esempio n. 13
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(id='lime_kiln',
                             processed_cargos_and_output_ratios=[('LIME', 4),
                                                                 ('PETR', 4),
                                                                 ('CLAY', 2)],
                             combined_cargos_boost_prod=True,
                             prod_cargo_types=['QLME', 'CMNT'],
                             prob_in_game='3',
                             prob_random='5',
                             prod_multiplier='[0, 0]',
                             map_colour='119',
                             name='string(STR_IND_LIME_KILN)',
                             nearby_station_name='string(STR_STATION_KILNS)',
                             fund_cost_multiplier='45',
                             graphics_change_dates=[1952, 1978])

industry.economy_variations['FIRS'].enabled = True

industry.add_tile(id='lime_kiln_tile_1',
                  animation_length=7,
                  animation_looping=True,
                  animation_speed=3,
                  location_checks=TileLocationChecks(
                      require_effectively_flat=True,
                      disallow_industry_adjacent=True))

sprite_ground = industry.add_sprite(
    sprite_number='GROUNDTILE_MUD_TRACKS'  # ground tile same as overlay tile
)
spriteset_ground_overlay = industry.add_spriteset(type='empty')
Esempio n. 14
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id='cement_plant',
    processed_cargos_and_output_ratios=[('COAL', 2), ('CLAY', 2), ('GRVL', 4)],
    combined_cargos_boost_prod=True,
    prod_cargo_types=['BDMT'],
    prob_in_game='3',
    prob_random='5',
    prod_multiplier='[0, 0]',
    map_colour='19',
    spec_flags='bitmask(IND_FLAG_MILITARY_HELICOPTER_CAN_EXPLODE)',
    name='string(STR_IND_CEMENT_PLANT)',
    nearby_station_name='string(STR_STATION_SILO)',
    fund_cost_multiplier='203')

industry.economy_variations['FIRS'].enabled = True
industry.economy_variations['FERNZ'].enabled = True
industry.economy_variations['MISTAH_KURTZ'].enabled = True
industry.economy_variations[
    'MISTAH_KURTZ'].processed_cargos_and_output_ratios = [('PETR', 2),
                                                          ('CLAY', 2),
                                                          ('GRVL', 4)]

industry.add_tile(id='cement_plant_tile_1',
                  animation_length=7,
                  animation_looping=True,
                  animation_speed=3,
                  custom_animation_control={
                      'macro':
                      'random_first_frame',
Esempio n. 15
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id='smithy_forge',
    processed_cargos_and_output_ratios=[('ACID', 2), ('COPR', 4), ('KAOL', 2)],
    combined_cargos_boost_prod=True,
    prod_cargo_types=['POWR', 'GOOD'],
    prob_in_game='2',
    prob_random='5',
    prod_multiplier='[0, 0]',
    map_colour='143',
    name='string(STR_IND_BATTERY_PLANT)',
    nearby_station_name='string(STR_STATION_BATTERY_PLANT)',
    fund_cost_multiplier='63',
    intro_year=1890)

industry.economy_variations['FIRS'].enabled = True

industry.add_tile(id='smithy_forge_tile_1',
                  animation_length=71,
                  animation_looping=True,
                  animation_speed=2,
                  location_checks=TileLocationChecks(
                      require_effectively_flat=True,
                      disallow_industry_adjacent=True))

spriteset_ground = industry.add_spriteset(type='cobble', )
spriteset_ground_overlay = industry.add_spriteset(type='empty')
spriteset_1 = industry.add_spriteset(sprites=[(10, 10, 64, 80, -31, -49)], )
# spriteset_2 was deprecated
spriteset_3 = industry.add_spriteset(sprites=[(150, 10, 64, 80, -31, -49)], )
Esempio n. 16
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(id='plastics_plant',
                             processed_cargos_and_output_ratios=[('RFPR', 6), ('FICR', 6), ('CHLO', 2)],
                             combined_cargos_boost_prod=True,
                             prod_cargo_types=['VPTS', 'MNSP'],
                             prob_in_game='3',
                             prob_random='5',
                             prod_multiplier='[0, 0]',
                             map_colour='209',
                             name='string(STR_IND_PLASTICS_PLANT)',
                             nearby_station_name='string(STR_STATION_MOULDINGS)',
                             fund_cost_multiplier='125',
                             intro_year='1900')

industry.economy_variations['FIRS'].enabled = True

industry.add_tile(id='plastics_plant_tile_1',
                  location_checks=TileLocationChecks(require_effectively_flat=True,
                                                     disallow_industry_adjacent=True))

spriteset_ground = industry.add_spriteset(
    type='concrete'
)
spriteset_ground_overlay = industry.add_spriteset(
    type='empty'
)
spriteset_1 = industry.add_spriteset(
    sprites=[(10, 10, 64, 62, -31, -31)],
)
spriteset_2 = industry.add_spriteset(
Esempio n. 17
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="blast_furnace",
    accept_cargos_with_input_ratios=[("IORE", 3), ("COAL", 2), ("SCMT", 3)],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[("STEL", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="10",
    name="string(STR_IND_BLAST_FURNACE)",
    nearby_station_name="string(STR_STATION_FURNACE)",
    fund_cost_multiplier="190",
    pollution_and_squalor_factor=2,
)

industry.economy_variations["STEELTOWN"].enabled = True
industry.economy_variations["STEELTOWN"].accept_cargos_with_input_ratios = [
    ("IORE", 3),
    ("COKE", 3),
    ("LIME", 2),
]
industry.economy_variations[
    "STEELTOWN"].prod_cargo_types_with_output_ratios = [
        ("IRON", 4),
        ("CSTI", 2),
        ("SLAG", 2),
    ]
industry.economy_variations["STEELTOWN"].prob_map_gen = "3"
industry.economy_variations[
    "STEELTOWN"].prob_in_game = "0"  # do not build during gameplay
Esempio n. 18
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="fertiliser_plant",
    accept_cargos_with_input_ratios=[
        ("UREA", 2),
        ("POTA", 2),
        ("PHAC", 2),
        ("NHNO", 2),
    ],
    prod_cargo_types_with_output_ratios=[("FMSP", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    prod_multiplier="[0, 0]",
    map_colour="191",
    name="string(STR_IND_FERTILISER_PLANT)",
    nearby_station_name="string(STR_STATION_BRINE_WORKS)",
    fund_cost_multiplier="170",
)

###industry.economy_variations['BETTER_LIVING_THROUGH_CHEMISTRY'].enabled = True

industry.add_tile(
    id="fertiliser_plant_tile_1",
    animation_length=7,
    animation_looping=True,
    animation_speed=3,
    location_checks=TileLocationChecks(require_effectively_flat=True,
                                       disallow_industry_adjacent=True),
)
industry.add_tile(
Esempio n. 19
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id='slag_grinding_plant',
    processed_cargos_and_output_ratios=[('SLAG', 8)],
    prod_cargo_types=['CMNT', 'FERT'],
    prob_in_game='2',
    prob_random='5',
    prod_multiplier='[0, 0]',
    map_colour='19',
    spec_flags='bitmask(IND_FLAG_MILITARY_AIRPLANE_CAN_EXPLODE)',
    # it's rare to force co-location of secondaries, but this one is near blast furnace by design
    location_checks=dict(industry_max_distance=['blast_furnace', 72],
                         same_type_distance=72),
    name='string(STR_IND_SLAG_GRINDING_PLANT)',
    nearby_station_name='string(STR_STATION_SILO)',
    fund_cost_multiplier='100 ')

industry.economy_variations['FIRS'].enabled = True

industry.add_tile(id='slag_grinding_plant_tile_1',
                  animation_length=7,
                  animation_looping=True,
                  animation_speed=3,
                  location_checks=TileLocationChecks(
                      require_effectively_flat=True,
                      disallow_industry_adjacent=True))

sprite_ground = industry.add_sprite(
    sprite_number='GROUNDTILE_MUD_TRACKS'  # ground tile same as overlay tile
)
Esempio n. 20
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(id='sawmill',
                             processed_cargos_and_output_ratios=[('WOOD', 6)],
                             prod_cargo_types=['WDPR'],
                             prob_in_game='3',
                             prob_random='5',
                             prod_multiplier='[0, 0]',
                             map_colour='194',
                             name='TTD_STR_INDUSTRY_NAME_SAWMILL',
                             nearby_station_name='string(STR_STATION_MILL)',
                             fund_cost_multiplier='97')

industry.economy_variations['FIRS'].enabled = True
industry.economy_variations['FERNZ'].enabled = True
industry.economy_variations['MISTAH_KURTZ'].enabled = True
industry.economy_variations['BASIC_ARCTIC'].enabled = True

industry.add_tile(id='sawmill_tile_1',
                  location_checks=TileLocationChecks(disallow_industry_adjacent=True))

sprite_ground = industry.add_sprite(
    sprite_number='GROUNDTILE_MUD_TRACKS'  # ground tile same as overlay tile
)

spriteset_ground_overlay = industry.add_spriteset(
    type='empty'
)
sprite_hut_1 = industry.add_sprite(
    sprite_number='2069'
)
Esempio n. 21
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id='assembly_plant',
    processed_cargos_and_output_ratios=[('VPTS', 4), ('VBOD', 4)],
    combined_cargos_boost_prod=True,
    prod_cargo_types=[('VEHI', 6), ('ENSP', 2)],
    prob_in_game='3',
    prob_random='5',
    prod_multiplier='[0, 0]',
    map_colour='141',
    name='string(STR_IND_ASSEMBLY_PLANT)',
    nearby_station_name='string(STR_STATION_AUTOMOTIVE)',
    fund_cost_multiplier='145')

industry.economy_variations['STEELTOWN'].enabled = True

industry.add_tile(id='assembly_plant_tile_1',
                  animation_length=71,
                  animation_looping=True,
                  animation_speed=2,
                  location_checks=TileLocationChecks(
                      require_effectively_flat=True,
                      disallow_industry_adjacent=True))

spriteset_ground = industry.add_spriteset(type='concrete', )
spriteset_ground_overlay = industry.add_spriteset(type='empty')
spriteset_1 = industry.add_spriteset(sprites=[(10, 10, 64, 80, -31, -49)], )
# spriteset_2 was deprecated
spriteset_3 = industry.add_spriteset(sprites=[(150, 10, 64, 80, -31, -49)], )
spriteset_4 = industry.add_spriteset(sprites=[(220, 10, 64, 80, -31, -49)], )
Esempio n. 22
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(id='electric_arc_furnace',
                             processed_cargos_and_output_ratios=[('SCMT', 6),
                                                                 ('QLME', 2)],
                             combined_cargos_boost_prod=True,
                             prod_cargo_types=[('STEL', 6), ('SLAG', 2)],
                             prob_in_game='3',
                             prob_random='5',
                             prod_multiplier='[0, 0]',
                             map_colour='209',
                             name='string(STR_IND_ELECTRIC_ARC_FURNACE)',
                             nearby_station_name='string(STR_STATION_FURNACE)',
                             fund_cost_multiplier='160',
                             intro_year=1832)

industry.economy_variations['FIRS'].enabled = True

industry.add_tile(id='electric_arc_furnace_tile_1',
                  animation_length=71,
                  animation_looping=True,
                  animation_speed=2,
                  custom_animation_control={
                      'macro':
                      'random_first_frame',
                      'animation_triggers':
                      'bitmask(ANIM_TRIGGER_INDTILE_CONSTRUCTION_STATE)'
                  },
                  location_checks=TileLocationChecks(
                      require_effectively_flat=True,
                      disallow_industry_adjacent=True))
Esempio n. 23
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="assembly_plant",
    accept_cargos_with_input_ratios=[
        ("VPTS", 2),
        ("VBOD", 2),
        ("VENG", 2),
        ("TYRE", 2),
    ],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[("VEHI", 6), ("ENSP", 1),
                                         ("FMSP", 1)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="141",
    name="string(STR_IND_ASSEMBLY_PLANT)",
    nearby_station_name="string(STR_STATION_AUTOMOTIVE)",
    fund_cost_multiplier="145",
)

industry.economy_variations["STEELTOWN"].enabled = True
industry.economy_variations[
    "STEELTOWN"].prob_in_game = "1"  # low chance of build during gameplay

industry.add_tile(
    id="assembly_plant_tile_1",
    animation_length=71,
    animation_looping=True,
    animation_speed=2,
    location_checks=TileLocationChecks(require_effectively_flat=True,
Esempio n. 24
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(id='paper_mill',
                             processed_cargos_and_output_ratios=[('CLAY', 2),
                                                                 ('WOOD', 4),
                                                                 ('SULP', 2)],
                             combined_cargos_boost_prod=True,
                             prod_cargo_types=['PAPR', 'MNSP'],
                             prob_in_game='3',
                             prob_random='5',
                             prod_multiplier='[0, 0]',
                             substitute='14',
                             map_colour='164',
                             fund_cost_multiplier='120',
                             nearby_station_name='string(STR_STATION_MILL)',
                             name='TTD_STR_INDUSTRY_NAME_PAPER_MILL',
                             override='14')

industry.economy_variations['FIRS'].enabled = True
industry.economy_variations['BASIC_ARCTIC'].enabled = True
industry.economy_variations['BASIC_ARCTIC'].prod_cargo_types = ['PAPR']
industry.economy_variations[
    'BASIC_ARCTIC'].processed_cargos_and_output_ratios = [('KAOL', 2),
                                                          ('WOOD', 4),
                                                          ('SULP', 2)]

# industry uses layouts and sprites from default game, no custom layouts etc

industry.add_tile(id='paper_mill_tile_1',
                  animation_length=7,
                  animation_looping=True,
Esempio n. 25
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="cement_plant",
    accept_cargos_with_input_ratios=[("COAL", 2), ("CLAY", 2), ("LIME", 4)],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[("CMNT", 8)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="19",
    special_flags=["IND_FLAG_MILITARY_HELICOPTER_CAN_EXPLODE"],
    name="string(STR_IND_CEMENT_PLANT)",
    nearby_station_name="string(STR_STATION_SILO)",
    fund_cost_multiplier="203",
)

# industry.economy_variations['BETTER_LIVING_THROUGH_CHEMISTRY'].enabled = True

industry.economy_variations["IN_A_HOT_COUNTRY"].enabled = True
industry.economy_variations[
    "IN_A_HOT_COUNTRY"].accept_cargos_with_input_ratios = [
        ("PETR", 2),
        ("CLAY", 2),
        ("GRVL", 4),
    ]
industry.economy_variations[
    "IN_A_HOT_COUNTRY"].prod_cargo_types_with_output_ratios = [("BDMT", 8)]
# industry.economy_variations['IN_A_HOT_COUNTRY'].accept_cargos_with_input_ratios = [('COAL', 2), ('CLAY', 2), ('GRVL', 4)]
# industry.economy_variations['IN_A_HOT_COUNTRY'].prod_cargo_types_with_output_ratios = [('CMNT', 8)]

industry.add_tile(
Esempio n. 26
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id='furniture_factory',
    processed_cargos_and_output_ratios=[('WDPR', 6)],
    prod_cargo_types=['GOOD'],
    prob_in_game='7',
    prob_random='8',
    prod_multiplier='[0, 0]',
    map_colour='186',
    name='string(STR_IND_FURNITURE_FACTORY)',
    nearby_station_name='string(STR_STATION_JOINERS_SHOP)',
    fund_cost_multiplier='95')

industry.economy_variations['FIRS'].enabled = True
industry.economy_variations['BASIC_ARCTIC'].enabled = True

industry.add_tile(id='furniture_factory_tile_1',
                  location_checks=TileLocationChecks(
                      require_effectively_flat=True,
                      disallow_industry_adjacent=True))

spriteset_ground = industry.add_spriteset(type='cobble', )
spriteset_ground_overlay = industry.add_spriteset(type='empty', )
spriteset_1 = industry.add_spriteset(sprites=[(10, 60, 64, 88, -31, -42)], )
spriteset_2 = industry.add_spriteset(sprites=[(80, 60, 64, 88, -31, -44)], )
spriteset_3 = industry.add_spriteset(sprites=[(150, 60, 64, 88, -31, -42)], )
spriteset_4 = industry.add_spriteset(sprites=[(220, 60, 64, 88, -31, -42)], )
spriteset_5 = industry.add_spriteset(sprites=[(290, 60, 64, 88, -31, -42)], )
spriteset_6 = industry.add_spriteset(sprites=[(360, 60, 64, 88, -31, -41)], )
Esempio n. 27
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="basic_oxygen_furnace",
    accept_cargos_with_input_ratios=[
        ("IRON", 4),
        ("MNO2", 2),
        ("QLME", 1),
        ("O2__", 1),
    ],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[("STCB", 4), ("STAL", 2),
                                         ("SLAG", 2)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="49",
    special_flags=["IND_FLAG_MILITARY_HELICOPTER_CAN_EXPLODE"],
    # it's rare to force co-location of secondaries, but this one is near blast furnace by design
    location_checks=dict(industry_max_distance=["blast_furnace", 72],
                         same_type_distance=72),
    name="string(STR_IND_BASIC_OXYGEN_FURNACE)",
    nearby_station_name="string(STR_STATION_FURNACE)",
    fund_cost_multiplier="160",
)

industry.economy_variations["STEELTOWN"].enabled = True
industry.economy_variations[
    "STEELTOWN"].prob_in_game = "0"  # do not build during gameplay

industry.add_tile(
    id="basic_oxygen_furnace_tile_1",
Esempio n. 28
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id='sugar_refinery',
    processed_cargos_and_output_ratios=[('MNSP', 3), ('SGBT', 5)],
    combined_cargos_boost_prod=True,
    prod_cargo_types=[('FOOD', 7), ('PEAT', 1)],
    prob_in_game='3',
    prob_random='5',
    prod_multiplier='[0, 0]',
    map_colour='83',
    spec_flags='bitmask(IND_FLAG_MILITARY_AIRPLANE_CAN_EXPLODE)',
    name='string(STR_IND_SUGAR_REFINERY)',
    nearby_station_name='string(STR_STATION_SUGAR_COMPANY)',
    fund_cost_multiplier='140')

industry.economy_variations['FIRS'].enabled = True

industry.add_tile(id='sugar_refinery_tile_1',
                  animation_length=7,
                  animation_looping=True,
                  animation_speed=3,
                  location_checks=TileLocationChecks(
                      require_effectively_flat=True,
                      disallow_industry_adjacent=True))

spriteset_ground = industry.add_spriteset(type='concrete')
spriteset_ground_overlay = industry.add_spriteset(type='empty')
spriteset_1 = industry.add_spriteset(sprites=[(10, 10, 64, 50, -31, -23)], )
spriteset_2 = industry.add_spriteset(sprites=[(80, 10, 64, 50, -31, -25)], )
spriteset_3 = industry.add_spriteset(sprites=[(150, 10, 64, 88, -31, -56)], )
Esempio n. 29
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="electric_arc_furnace",
    accept_cargos_with_input_ratios=[
        ("SCMT", 4),
        ("FECR", 2),
        ("QLME", 1),
        ("O2__", 1),
    ],
    combined_cargos_boost_prod=True,
    prod_cargo_types_with_output_ratios=[("STCB", 4), ("STST", 2),
                                         ("SLAG", 2)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="186",
    name="string(STR_IND_ELECTRIC_ARC_FURNACE)",
    nearby_station_name="string(STR_STATION_FURNACE)",
    fund_cost_multiplier="160",
    pollution_and_squalor_factor=2,
)

industry.economy_variations["STEELTOWN"].enabled = True
industry.economy_variations[
    "STEELTOWN"].prob_in_game = "1"  # low chance of build during gameplay

industry.add_tile(
    id="electric_arc_furnace_tile_1",
    animation_length=71,
    animation_looping=True,
    animation_speed=2,
Esempio n. 30
0
from industry import IndustrySecondary, TileLocationChecks

industry = IndustrySecondary(
    id="pyrite_smelter",
    accept_cargos_with_input_ratios=[("PORE", 8)],
    prod_cargo_types_with_output_ratios=[("ZINC", 4), ("SULP", 4)],
    prob_in_game="3",
    prob_map_gen="5",
    map_colour="19",
    # it's rare to force co-location of secondaries, but this one is near pyrite mine by design
    location_checks=dict(industry_max_distance=["pyrite_mine", 72],
                         same_type_distance=100),
    special_flags=["IND_FLAG_MILITARY_HELICOPTER_CAN_EXPLODE"],
    name="string(STR_IND_PYRITE_SMELTER)",
    nearby_station_name="string(STR_STATION_SMELTER)",
    fund_cost_multiplier="120",
)

industry.economy_variations["BASIC_ARCTIC"].enabled = True

industry.add_tile(
    id="pyrite_smelter_tile_1",
    animation_length=7,
    animation_looping=True,
    animation_speed=3,
    custom_animation_control={
        "macro": "random_first_frame",
        "animation_triggers":
        "bitmask(ANIM_TRIGGER_INDTILE_CONSTRUCTION_STATE)",
    },
    location_checks=TileLocationChecks(require_effectively_flat=True,