Prototype/Fluid: Difference between revisions

From Official Factorio Wiki
Jump to navigation Jump to search
(overhaul to include Prototype)
Line 1: Line 1:
== Mandatory properties ==
== Mandatory properties ==
 
Inherits all properties from [[Prototype]].
=== type ===
'''Type''': [[Types/string]]
 
Must be "fluid".
 
=== name ===
'''Type''': [[Types/string]]


=== icon ===
=== icon ===
'''Type''': [[Types/FileName]]
'''Type''': [[Types/FileName]]
=== order ===
'''Type''': [[Types/Order]]


=== default_temperature ===
=== default_temperature ===

Revision as of 12:59, 23 January 2018

Mandatory properties

Inherits all properties from Prototype.

icon

Type: Types/FileName

default_temperature

Type: Types/uint

max_temperature

Type: Types/uint

base_color

Type: Types/color

flow_color

Type: Types/color

pressure_to_speed_ratio

Type: Types/double

flow_to_energy_ratio

Type: Types/double

Optional properties

heat_capacity

Type: Types/EnergyAmount

Joule needed to heat 1 Unit by 1 °C.

gas_temperature

Type: Types/uint

auto_barrel

Type: Types/bool

Whether the fluid should be included in the barrel recipes automatically generated in data-updates.lua in the base mod.

Example

{
    type = "fluid",
    name = "water",
    default_temperature = 15,
    max_temperature = 100,
    heat_capacity = "0.2KJ",
    base_color = {r=0, g=0.34, b=0.6},
    flow_color = {r=0.7, g=0.7, b=0.7},
    icon = "__base__/graphics/icons/fluid/water.png",
    order = "a[fluid]-a[water]",
    pressure_to_speed_ratio = 0.4,
    flow_to_energy_ratio = 0.59
  },