[0.17.60] Fluid box collision problem, possibly.
Posted: Fri Aug 02, 2019 10:34 pm
Here is some code that makes a new boiler out of the old boiler and adds a pipe to it:
This code causes an error due to a fluid box overlap, but the other positions are not the same:
Code: Select all
gf_boiler_entity = util.table.deepcopy(data.raw.boiler.boiler)
gf_boiler_entity.name = "adamo-carbon-gas-fired-boiler"
gf_boiler_entity.icon = "__adamo-carbon__/graphics/icons/gas-fired-boiler.png"
gf_boiler_entity.icon_size = 32
gf_boiler_entity.minable.result = "adamo-carbon-gas-fired-boiler"
gf_boiler_entity.energy_source = {
type = "fluid",
fluid_box = {
base_area = 1,
height = 2,
base_level = -1,
pipe_covers = pipecoverspictures(),
pipe_picture = assembler1pipepictures(),
pipe_connections = {
{type = "input", position = {0, 1.5}},
},
},
burns_fluid = true,
scale_fluid_usage = true,
effectivity = 1,
emissions_per_minute = 30,
smoke = {{
name = "smoke",
north_position = util.by_pixel(-38, -47.5),
south_position = util.by_pixel(38.5, -32),
east_position = util.by_pixel(20, -70),
west_position = util.by_pixel(-19, -8.5),
frequency = 15,
starting_vertical_speed = 0.3,
starting_frame_deviation = 0
}},
light_flicker = {
--minimum_intensity = 0.8,
--maximum_intensity = 1,
--color = {r=0.75,g=0.1,b=0.1,a=0.5},
color = {r=1,g=0.5,b=0.5,a=0.5},
minimum_light_size = 0.1,
light_intensity_to_size_coefficient = 1
}
}
Code: Select all
output_fluid_box =
{
base_area = 1,
height = 2,
base_level = 1,
pipe_covers = pipecoverspictures(),
pipe_connections =
{
{type = "output", position = {0, -1.5}}
},
production_type = "output",
filter = "steam"
},
Code: Select all
fluid_box =
{
base_area = 1,
height = 2,
base_level = -1,
pipe_covers = pipecoverspictures(),
pipe_connections =
{
{type = "input-output", position = {-2, 0.5}},
{type = "input-output", position = {2, 0.5}}
},
production_type = "input-output",
filter = "water"
},