Create: Computing AgesBrass Docs
Devices

Create: New Age

The motors, energy blocks, heat blocks and nuclear reactor of Create: New Age, driven by a computer: speeds, energy, temperatures and fuel.

Needs Create: New Age

The blocks on this page belong to Create: New Age. Without that mod, there is no such block, and peripheral.find("motor") returns nil.

Create: New Age brings electricity and heat to Create. Its motors turn shafts with energy, its generator coils and carbon brushes make that energy from rotation, wires between electrical connectors carry it, energisers charge items with it and street lights burn it. Heat flows from block to block: solar plates and heat pipes collect it, heaters give it to boilers, Stirling engines turn it back into rotation, and a nuclear reactor makes a great deal of it. A computer sets the speed and the power of the motors, follows the energy, and watches the temperatures before something melts or explodes.

Block (in game)peripheral typewhat it reads or sets
Basic, Advanced and Reinforced Motormotorits speed (set), whether it turns, the stress it gives, the energy it uses, its redstone mode
Basic and Advanced Motor Extensionmotor_extensionthe stress multiplier of its motor (set)
Carbon Brushescarbon_brushesthe energy they collect from generator coils
Basic, Advanced and Reinforced Energiserenergiserits energy, the charge of the item under it
Electrical Connectorelectrical_connectorits mode (set), its wires
Street Lightstreet_lightits light level (set), the light it gives
Heaterheatertemperature, the heat it gives a boiler
Heat Pipeheat_pipetemperature, the heat it gains
Heat Pumpheat_pumptemperature, the heat it pushes
Basic and Advanced Solar Heating Platesolar_heating_platetemperature, the heat it makes
Stirling Enginestirling_enginetemperature, the speed it makes
Reactor Rodreactor_rodtemperature, its fuel, whether it burns
Reactor Heat Ventreactor_heat_venttemperature, the heat it takes from the rods
Reactor Fuel Acceptorreactor_fuel_acceptorits rods: how many, their fuel, the hottest

Reaching a block. Against the computer, a block is called by its side ("left"...); on a Data Cable (Minicomputer and newer) it gets a name such as motor@12,64,-30. peripheral.find("motor") gives the first one, peripheral.list("motor") the names of all of them.

Brass
local motor = peripheral.find("motor")
print("tier " .. motor.tier() .. ", " .. motor.speed() .. " RPM, " .. motor.energy_consumption() .. " FE/t")
Note

New Age gives its motors, carbon brushes and energisers a ComputerCraft peripheral. Its methods are all here, under this mod's names: getTier() becomes tier(), getOutput() is output(), getMaxEnergy() and getCurrentEnergy() are max_energy() and current_energy(). The other methods are new.

What comes back. Each call reads the block again, so a value is always fresh; numbers are rounded to 3 decimals. When something is wrong, the call stops the program with an error you can catch with pcall:

errorwhen
motor removedthe block was broken or replaced since peripheral.wrap (its type, with spaces: heat pipe removed)
peripheral is not loadedthe chunk of the block is not loaded
bad argument #1 to 'set_speed' (...)a wrong argument: a speed of 0, a number with decimals, an unknown mode
this version of Create: New Age has no getHeatyour version of New Age lacks what the method reads (the name at the end)
Create: New Age error: ...the block itself failed while answering

When a change happens. set_speed, set_multiplier, set_mode and set_light_level act at the end of the tick, like a wrench: a program that sets the same block several times in one tick keeps the last value. set_inverted acts at once.

Generic methods too. Several of these blocks also have the methods of a generic type (see Peripherals):

  • Create kinetic blocks: motors, carbon brushes, energisers and Stirling engines turn, so they have stress(), capacity() and overstressed(). A motor's own speed() and set_speed() hide the kinetic ones: its speed() is the speed set on the motor, not the speed of its shaft (0 while it is stopped). motor.active() tells whether it turns.
  • Energy blocks: New Age counts energy in Forge Energy (FE, the ⚡ of its tooltips), so energy() and energy_capacity() read the storage of a motor, carbon brushes, an energiser or a street light. An electrical connector holds nothing (it hands the energy to its network): it answers 0 and a huge capacity that means nothing.
  • Inventories: the reactor fuel acceptor has three slots for fuel, which count() and push() reach.
Methods
motor.tier()Which motor it is: the tier sets its top speed, its stress and its storage. This is getTier() of New Age's ComputerCraft peripheral.
motor.speed()The speed set on the motor's value box, in RPM, whether it turns or not: a motor stopped by redstone or out of energy still answers the speed it will turn at. It hides kinetic.speed(), the speed of the shaft. A new motor is set to 16 RPM.
motor.set_speed(rpm)Sets the speed, like the wrench on its value box, and returns the value kept: between minus and plus the top speed of the motor (128 RPM basic, 256 advanced and reinforced, by default). The motor takes it at the end of the tick. Its stress and its energy use stay the same at any speed.
motor.active()true while the motor turns: it has energy, and its redstone lets it run. false while redstone stops it or its storage is empty.
motor.stress_capacity()The stress capacity the motor adds to its network now, in SU: the stress of its tier times the multiplier of its extension, at any speed. Less when its storage runs dry, 0 while it is stopped. The kinetic capacity() is the capacity of the whole network.
motor.energy_consumption()The energy the motor took from its storage in the last tick, in FE: 15, 60 or 240 FE per tick by tier with the default settings, times the multiplier of its extension. 0 while it is stopped. With energy(), it tells how long the motor runs on its storage alone:
motor.inverted()false by default: the motor runs without redstone and stops with it. true once inverted (by a wrench or by set_inverted(true)): it runs only while it gets a redstone signal.
motor.set_inverted(inverted)Chooses how the motor follows redstone, like a right-click with a wrench, at once. An inverted motor against the computer runs while the computer powers it:
ext.multiplier()The multiplier set on the extension, in percent: 100 gives the motor its own stress, 200 twice that for twice the energy. A new extension is set to 100.
ext.set_multiplier(percent)Sets the multiplier, like the wrench on its value box, and returns the value kept: from 1 to 200 % on a basic extension, to 800 % on an advanced one, by default (server config basicMotorExtensionMultiplier and advancedMotorExtensionMultiplier). Any whole percent works, finer than the steps of the value box. It acts at the end of the tick.
brushes.output()The energy the brushes collected from their coils in the last tick, in FE: the "Energy Output" of Engineer's Goggles, and getOutput() of New Age's ComputerCraft peripheral. 0 while the coils stand still.
connector.mode()"pull" when the connector takes the energy of the block it sits on, "inert" when it does not. A new connector is inert.
connector.set_mode(mode)Sets the mode, like a wrench on the connector, at the end of the tick; the network then looks again at what gives energy and what takes it. Another word stops the program with bad argument #1 to 'set_mode' (inert, pull).
connector.connections()How many wires leave the connector: 0 for a connector alone, which only serves its own block.
energiser.tier()Which energiser it is: getTier() of New Age's ComputerCraft peripheral.
energiser.max_energy()10,000, 100,000 or 1,000,000 FE by tier: getMaxEnergy() of the ComputerCraft peripheral, the same number as energy_capacity().
energiser.current_energy()The energy in the energiser now: getCurrentEnergy() of the ComputerCraft peripheral, the same number as energy().
energiser.running()true while an item under the energiser is being energised or charged. It turns false when the item is done, or half a second after it left.
energiser.progress()For a recipe, the energy put in so far over the energy the whole stack needs; for an item that holds energy, how full it is. 0 while the energiser is idle.
energiser.energy_consumption()The energy the energiser put into the item in the last tick, in FE: at most 4, 16 or 64 FE by tier for every 10 RPM of its shaft, less when its storage runs low. 0 while it is idle.
lamp.light_level()The level set on its value box, from 0 to 15, whether it has energy or not. A new street light is set to 15.
lamp.set_light_level(level)Sets the level, like the wrench on its value box, at the end of the tick. 0 turns the light off, and then it burns no energy. Street lights that only light up at night:
lamp.light()The light the street light gives now: its level while it has energy, 0 once its storage is empty.
block.temperature()The temperature of the block, as Engineer's Goggles show it. All seven heat blocks have it. Most of them change once a second; a burning reactor rod changes every tick.
block.max_temperature()The temperature above which the block is destroyed: 10,000 ˚T, or 26,000 ˚T for a reactor rod, times the server config overheatingMultiplier (1 by default). Above it, a heat block turns into lava; a burning reactor rod explodes and leaves corium. nil when the server turns overheating off (overheatingMultiplier at -1). All seven heat blocks have it. Engineer's Goggles write the temperature in yellow from 65 % of it, gold from 75 %, red from 90 %.
heater.heat()Heater only. The heat it gives the boiler or the basin above it, in the words of a Blaze Burner. Once a second it turns its heat into a level and uses that heat up: over 500 ˚T it is "seething" and uses 500, over 400 "kindled" (400), over 100 "fading" (100), over 50 "smouldering" (50), below that "none" (server config boilerRequiredHeatMultiplier). So it stays seething only while it gets about 500 ˚T a second. A boiler counts "fading", "kindled" and "seething" as 1, 2 and 3 levels of heat, "smouldering" as passive heat.
plate.generating()Heat Pipe and Solar Heating Plate only.
pump.pumped()Heat Pump only. Once a second, the pump pushes all its heat into the heat block in front of it, as much as that block can still take, then loses 4 ˚T of what is left. This is what it pushed: 0 when nothing in front takes heat.
engine.generated_speed()Stirling Engine only. Once a second, over 100 ˚T the engine uses 100 and turns at 32 RPM; over 50 ˚T, it uses 50 and turns at 16 RPM; below that, it stops. It takes heat only from the block under it, and gives 512 SU at 16 RPM, 1,024 SU at 32. The kinetic speed() gives the speed of its shaft.
rod.fuel()Reactor Rod only. How long the rod still burns, in seconds: up to 17,280 (4 h 48 min) once the fuel acceptor has filled it.
rod.active()Reactor Rod only. true while the rod has fuel: it glows, heats and gives off radiation. Only a burning rod explodes, when it overheats or when it is broken.
vent.extracting()Reactor Heat Vent only. The heat the vent took from its rods in the last second. It takes from each rod as much as it can hold, up to 10,000 ˚T in the vent: when the vent nears 10,000 ˚T, it takes nothing more and the rods heat up. Carry its heat away to keep it taking.
acceptor.rods()The rods in a straight line from the faces of the acceptor, as it finds them itself (up to 32 per line). 0 means it feeds nothing: check where it stands.
acceptor.fuel()The fuel of its rods, in seconds: their mean, which is also what each one holds, since the acceptor shares the fuel every second. 0 without rods.
acceptor.temperature()The temperature of the hottest of its rods: one call watches the whole reactor, even with no rod in reach of the computer. 0 without rods.

Motors

A motor turns its shaft with energy. It stores energy (16,000 FE basic, 64,000 advanced, 128,000 reinforced) and gives the same stress at any speed: 512 SU basic, 2,048 advanced, 8,192 reinforced, for 15, 60 and 240 FE per tick, with the default settings (server config, section Motors). It turns up to 128 RPM (basic) or 256 RPM (advanced and reinforced), either way, never at 0. When its storage runs dry it gives less stress, then stops.

Redstone stops it. A motor runs without redstone and stops while it gets a signal. A wrench (right-click) inverts that: it then runs only while it gets a signal. A motor against the computer follows rs.set (see rs).

The extension. A Motor Extension behind a motor (on the side opposite its shaft, facing the same way) multiplies the motor's stress, and its energy use with it, by the extension's multiplier: up to 200 % (basic) or 800 % (advanced). It also adds 64,000 or 256,000 FE to the motor's storage.

#

motor.tier()

→ number

Which motor it is: the tier sets its top speed, its stress and its storage. This is getTier() of New Age's ComputerCraft peripheral.

Returns
number
1 basic, 2 advanced, 3 reinforced
Brass
local motor = peripheral.find("motor")
local names = {"basic", "advanced", "reinforced"}
print(names[motor.tier()] .. " motor")

See also motor.set_speed()

#

motor.speed()

→ number

The speed set on the motor's value box, in RPM, whether it turns or not: a motor stopped by redstone or out of energy still answers the speed it will turn at. It hides kinetic.speed(), the speed of the shaft. A new motor is set to 16 RPM.

Returns
number
the speed set on the motor, in RPM, negative the other way; never 0
Brass
local motor = peripheral.find("motor")
if motor.active() then
  print("turning at " .. motor.speed() .. " RPM")
else
  print("stopped, set to " .. motor.speed() .. " RPM")
end

See also motor.set_speed() motor.active()

#

motor.set_speed(rpm)

→ number

Sets the speed, like the wrench on its value box, and returns the value kept: between minus and plus the top speed of the motor (128 RPM basic, 256 advanced and reinforced, by default). The motor takes it at the end of the tick. Its stress and its energy use stay the same at any speed.

Parameters
rpm number
the new speed, a whole number of RPM, negative to turn the other way, never 0
Returns
number
the speed kept, within the top speed of the motor
Brass
local motor = peripheral.find("motor")
print(motor.set_speed(64))
print(motor.set_speed(-32))
print(motor.set_speed(1000))

On a basic motor with the default settings, this prints 64, -32 (the other way) and 128 (its top speed). A speed of 0 stops the program with bad argument #1 to 'set_speed' (a motor never turns at 0: stop it with redstone), a number with decimals with bad argument #1 to 'set_speed' (number has no integer representation).

See also motor.speed() motor.tier()

#

motor.active()

→ boolean

true while the motor turns: it has energy, and its redstone lets it run. false while redstone stops it or its storage is empty.

Returns
boolean
true while the motor turns
Brass
local motor = peripheral.find("motor")
if not motor.active() and motor.energy() == 0 then
  print("the motor is out of energy")
end

See also motor.speed() motor.inverted()

#

motor.stress_capacity()

→ number

The stress capacity the motor adds to its network now, in SU: the stress of its tier times the multiplier of its extension, at any speed. Less when its storage runs dry, 0 while it is stopped. The kinetic capacity() is the capacity of the whole network.

Returns
number
the stress the motor gives now, in SU; 0 while it is stopped
Brass
local motor = peripheral.find("motor")
print(motor.stress_capacity() .. " of the " .. motor.capacity() .. " SU of the network")

See also motor.energy_consumption() motor_extension.multiplier()

#

motor.energy_consumption()

→ number

The energy the motor took from its storage in the last tick, in FE: 15, 60 or 240 FE per tick by tier with the default settings, times the multiplier of its extension. 0 while it is stopped. With energy(), it tells how long the motor runs on its storage alone:

Returns
number
the energy the motor used in the last tick, in FE; 0 while it is stopped
Brass
local motor = peripheral.find("motor")
local use = motor.energy_consumption()
if use > 0 then
  print(math.floor(motor.energy() / use / 20) .. " s of energy left")
end

See also motor.stress_capacity()

#

motor.inverted()

→ boolean

false by default: the motor runs without redstone and stops with it. true once inverted (by a wrench or by set_inverted(true)): it runs only while it gets a redstone signal.

Returns
boolean
true when the motor runs only with redstone
Brass
local motor = peripheral.find("motor")
print(motor.inverted())

See also motor.set_inverted()

#

motor.set_inverted(inverted)

Chooses how the motor follows redstone, like a right-click with a wrench, at once. An inverted motor against the computer runs while the computer powers it:

Parameters
inverted boolean
true to run only with redstone, false to stop with redstone
Brass
local motor = peripheral.wrap("left")
motor.set_inverted(true)
rs.set("left", true)   -- runs
sleep(10)
rs.set("left", false)  -- stops

See also motor.inverted() motor.active()

Motor extensions

#

ext.multiplier()

→ number

The multiplier set on the extension, in percent: 100 gives the motor its own stress, 200 twice that for twice the energy. A new extension is set to 100.

Returns
number
the multiplier of the extension, in percent
Brass
local ext = peripheral.find("motor_extension")
print(ext.multiplier() .. " %")

See also motor_extension.set_multiplier() motor.stress_capacity()

#

ext.set_multiplier(percent)

→ number

Sets the multiplier, like the wrench on its value box, and returns the value kept: from 1 to 200 % on a basic extension, to 800 % on an advanced one, by default (server config basicMotorExtensionMultiplier and advancedMotorExtensionMultiplier). Any whole percent works, finer than the steps of the value box. It acts at the end of the tick.

Parameters
percent number
the new multiplier, a whole number of percent
Returns
number
the multiplier kept, from 1 to 200 (basic) or 800 (advanced)

Below 100 %, the motor gives less stress and uses less energy: a program can save energy while the machines rest.

Brass
local ext = peripheral.find("motor_extension")
print(ext.set_multiplier(50))   -- half the stress, half the energy

See also motor_extension.multiplier()

Making and carrying energy

Carbon brushes. Generator coils turned by a shaft and surrounded by magnets make energy. Carbon Brushes collect it, from up to 8 coils in line with them (server config maxCoils), and push it into the blocks around them: a machine, or an Electrical Connector that sends it down the wires.

#

brushes.output()

→ number

The energy the brushes collected from their coils in the last tick, in FE: the "Energy Output" of Engineer's Goggles, and getOutput() of New Age's ComputerCraft peripheral. 0 while the coils stand still.

Returns
number
the energy the brushes collected in the last tick, in FE
Brass
local brushes = peripheral.find("carbon_brushes")
local out = brushes.output()
print(out .. " FE/t, " .. out * 20 .. " FE/s")

Wires. Electrical Connectors linked by wires make a network. Each connector gives energy to the block it sits on, when that block takes energy. In pull mode it also takes energy from that block: that is for the batteries and generators of other mods, which do not push their energy themselves. In inert mode it does not. A block that pushes its energy, such as Carbon Brushes, feeds the network in both modes.

#

connector.mode()

→ string

"pull" when the connector takes the energy of the block it sits on, "inert" when it does not. A new connector is inert.

Returns
string
"pull" or "inert"
Brass
local connector = peripheral.find("electrical_connector")
print(connector.mode())

See also electrical_connector.set_mode()

#

connector.set_mode(mode)

Sets the mode, like a wrench on the connector, at the end of the tick; the network then looks again at what gives energy and what takes it. Another word stops the program with bad argument #1 to 'set_mode' (inert, pull).

Parameters
mode string
"pull" or "inert"

A connector in pull mode on a battery is a switch for what the battery gives: "inert" stops it feeding the network (the network can still charge it), "pull" lets it give again.

Brass
local connector = peripheral.find("electrical_connector")
connector.set_mode("inert")

See also electrical_connector.mode()

#

connector.connections()

→ number

How many wires leave the connector: 0 for a connector alone, which only serves its own block.

Returns
number
the number of wires attached to the connector
Brass
for _, name in ipairs(peripheral.list("electrical_connector")) do
  print(name .. ": " .. peripheral.wrap(name).connections() .. " wires")
end

Using energy

Energiser. Above a Depot or a belt, with rotation and energy, an Energiser energises the items under it: it turns them into their energising recipe, or fills the items that hold energy. It stores 10,000, 100,000 or 1,000,000 FE by tier, and puts into an item 4, 16 or 64 FE per tick for every 10 RPM (server config energiserSpeedMultiplier).

#

energiser.tier()

→ number

Which energiser it is: getTier() of New Age's ComputerCraft peripheral.

Returns
number
1 basic, 2 advanced, 3 reinforced
Brass
local energiser = peripheral.find("energiser")
print("tier " .. energiser.tier())
#

energiser.max_energy()

→ number

10,000, 100,000 or 1,000,000 FE by tier: getMaxEnergy() of the ComputerCraft peripheral, the same number as energy_capacity().

Returns
number
the most energy the energiser stores, in FE
Brass
local energiser = peripheral.find("energiser")
print(math.floor(energiser.current_energy() / energiser.max_energy() * 100) .. " % full")

See also energiser.current_energy()

#

energiser.current_energy()

→ number

The energy in the energiser now: getCurrentEnergy() of the ComputerCraft peripheral, the same number as energy().

Returns
number
the energy the energiser stores now, in FE
Brass
local energiser = peripheral.find("energiser")
print(energiser.current_energy() .. " FE")

See also energiser.max_energy()

#

energiser.running()

→ boolean

true while an item under the energiser is being energised or charged. It turns false when the item is done, or half a second after it left.

Returns
boolean
true while the energiser works on an item
Brass
local energiser = peripheral.find("energiser")
print(energiser.running())

See also energiser.progress()

#

energiser.progress()

→ number

For a recipe, the energy put in so far over the energy the whole stack needs; for an item that holds energy, how full it is. 0 while the energiser is idle.

Returns
number
how far the item is, from 0 to 1; 0 when the energiser is idle
Brass
local energiser = peripheral.find("energiser")
if energiser.running() then
  print(math.floor(energiser.progress() * 100) .. " %")
end

See also energiser.running()

#

energiser.energy_consumption()

→ number

The energy the energiser put into the item in the last tick, in FE: at most 4, 16 or 64 FE by tier for every 10 RPM of its shaft, less when its storage runs low. 0 while it is idle.

Returns
number
the energy put into the item in the last tick, in FE; 0 when idle
Brass
local energiser = peripheral.find("energiser")
print(energiser.energy_consumption() .. " FE/t at " .. energiser.speed() .. " RPM")

Street light. A Street Light is also a connector: wires attach to it. It stores 10,000 FE and burns 1 FE per tick for each level of light (server config streetLightCapacity and streetLightLevelExtraction). Without energy it goes dark.

#

lamp.light_level()

→ number

The level set on its value box, from 0 to 15, whether it has energy or not. A new street light is set to 15.

Returns
number
the light level set on the street light, from 0 to 15
Brass
local lamp = peripheral.find("street_light")
print(lamp.light_level(), lamp.light())

See also street_light.set_light_level() street_light.light()

#

lamp.set_light_level(level)

Sets the level, like the wrench on its value box, at the end of the tick. 0 turns the light off, and then it burns no energy. Street lights that only light up at night:

Parameters
level number
the new light level, a whole number, kept between 0 and 15
Brass
while true do
  local t = os.day_time()
  local level = (t >= 13000 and t < 23000) and 15 or 0
  for _, name in ipairs(peripheral.list("street_light")) do
    peripheral.wrap(name).set_light_level(level)
  end
  sleep(10)
end

See also street_light.light_level()

#

lamp.light()

→ number

The light the street light gives now: its level while it has energy, 0 once its storage is empty.

Returns
number
the light the street light gives now, from 0 to 15
Brass
local lamp = peripheral.find("street_light")
if lamp.light_level() > 0 and lamp.light() == 0 then
  print("the street light has no energy")
end

See also street_light.light_level()

Heat

New Age counts heat in ˚T. Every heat block has a temperature, and once a second it shares it with the heat blocks touching it: they all take the average, so heat spreads along pipes from where it is made to where it is used. Some faces stay out: the top of a Heater and of a Solar Heating Plate, every face of a Stirling Engine but its bottom. A Heat Pump takes heat on its other faces and pushes it out of its front.

  • Made by Solar Heating Plates in the sun, by Heat Pipes over a heat source, and by the reactor through its heat vents.
  • Used by Heaters, which heat a boiler or a basin like a Blaze Burner, and by Stirling Engines, which turn it into rotation.

Too hot. Above its max_temperature(), a heat block turns into lava, and a burning reactor rod explodes. The seven heat blocks have temperature() and max_temperature(); each also has its own methods:

Blockits own methods
Heaterheat_block.heat()
Heat Pipe, Solar Heating Plateheat_block.generating()
Heat Pumpheat_block.pumped()
Stirling Engineheat_block.generated_speed()
Reactor Rodheat_block.fuel(), heat_block.active()
Reactor Heat Ventheat_block.extracting()
#

block.temperature()

→ number

The temperature of the block, as Engineer's Goggles show it. All seven heat blocks have it. Most of them change once a second; a burning reactor rod changes every tick.

Returns
number
the temperature of the block, in ˚T
Brass
local block = peripheral.find("heat_pipe")
print("temperature " .. block.temperature())

See also heat_block.max_temperature()

#

block.max_temperature()

→ number|nil

The temperature above which the block is destroyed: 10,000 ˚T, or 26,000 ˚T for a reactor rod, times the server config overheatingMultiplier (1 by default). Above it, a heat block turns into lava; a burning reactor rod explodes and leaves corium. nil when the server turns overheating off (overheatingMultiplier at -1). All seven heat blocks have it. Engineer's Goggles write the temperature in yellow from 65 % of it, gold from 75 %, red from 90 %.

Returns
number|nil
the temperature the block melts or explodes above, in ˚T; nil when overheating is off
Brass
local block = peripheral.find("heat_pipe")
local max = block.max_temperature()
if max then
  print(math.floor(block.temperature() / max * 100) .. " % of its limit")
end

See also heat_block.temperature()

#

heater.heat()

→ string

Heater only. The heat it gives the boiler or the basin above it, in the words of a Blaze Burner. Once a second it turns its heat into a level and uses that heat up: over 500 ˚T it is "seething" and uses 500, over 400 "kindled" (400), over 100 "fading" (100), over 50 "smouldering" (50), below that "none" (server config boilerRequiredHeatMultiplier). So it stays seething only while it gets about 500 ˚T a second. A boiler counts "fading", "kindled" and "seething" as 1, 2 and 3 levels of heat, "smouldering" as passive heat.

Returns
string
"none", "smouldering", "fading", "kindled" or "seething"
Brass
local heater = peripheral.find("heater")
if heater.heat() ~= "seething" then
  print("the boiler is short of heat: " .. heater.heat())
end

See also heat_block.temperature()

#

plate.generating()

→ number

Heat Pipe and Solar Heating Plate only.

Returns
number
the heat the block gained in the last second, in ˚T

On a Solar Heating Plate, the heat it made in the last second: up to 20 ˚T (basic) or 60 ˚T (advanced) under a clear sky, less in the rain, at dusk or in the shade, nothing at night (server config solarPanelHeatMultiplier). It makes less once it is hotter than 400 ˚T (basic) or 1,200 ˚T (advanced): a plate whose heat nobody takes stays there.

On a Heat Pipe, the heat it drew in the last second from the block under it, when that block heats a Create boiler (lava, a Blaze Burner, a Heater): 6 ˚T from passive heat such as lava, 24 from a lit Blaze Burner, 42 from a superheated one, and nothing more once the pipe reaches 900, 1,200 or 1,800 ˚T. Minus the 1 ˚T every pipe loses each second (server config passivePipeHeatLoss): a pipe over lava answers 5, a pipe with nothing under it -1.

Brass
local plate = peripheral.find("solar_heating_plate")
print("the sun gives " .. plate.generating() .. " a second")
#

pump.pumped()

→ number

Heat Pump only. Once a second, the pump pushes all its heat into the heat block in front of it, as much as that block can still take, then loses 4 ˚T of what is left. This is what it pushed: 0 when nothing in front takes heat.

Returns
number
the heat the pump pushed out in the last second, in ˚T
Brass
local pump = peripheral.find("heat_pump")
if pump.pumped() == 0 and pump.temperature() > 0 then
  print("the pump is blocked: nothing in front takes its heat")
end
#

engine.generated_speed()

→ number

Stirling Engine only. Once a second, over 100 ˚T the engine uses 100 and turns at 32 RPM; over 50 ˚T, it uses 50 and turns at 16 RPM; below that, it stops. It takes heat only from the block under it, and gives 512 SU at 16 RPM, 1,024 SU at 32. The kinetic speed() gives the speed of its shaft.

Returns
number
the speed the engine makes, 0, 16 or 32 RPM
Brass
local engine = peripheral.find("stirling_engine")
print(engine.generated_speed() .. " RPM")

The nuclear reactor

A reactor is a group of Reactor Rods, fed by a Reactor Fuel Acceptor and cooled by Reactor Heat Vents. With the default settings (the thresholds scale with overheatingMultiplier):

  • The rods burn their fuel, one tick of fuel each tick, and gain 30 ˚T each tick, 600 a second (server config ReactorRodHeat). Above 16,000 ˚T a rod loses 25 ˚T a tick (ReactorRodHeatLoss): it still climbs, more slowly. Rods side by side share their heat about every 2 seconds. A burning rod whose heat nobody takes reaches its limit of 26,000 ˚T in about two minutes, and explodes.
  • The fuel acceptor has three slots for Nuclear Fuel. Once a second it finds the rods in a straight line from each of its faces (up to 32 per line, server config maxRodsInDirection), fills them from its slots, up to 4 h 48 min of fuel each (345,600 ticks), and spreads the fuel so they all hold the same. One Nuclear Fuel burns 24 minutes in one rod (28,800 ticks), shared among all the rods.
  • The heat vents take the heat out of the rods in a straight line from each of their faces, as long as they hold less than 10,000 ˚T, and share it with the heat blocks touching them: heat pipes, which carry it to heaters or Stirling engines.
#

rod.fuel()

→ number

Reactor Rod only. How long the rod still burns, in seconds: up to 17,280 (4 h 48 min) once the fuel acceptor has filled it.

Returns
number
the fuel left in the rod, in seconds
Brass
local rod = peripheral.find("reactor_rod")
local s = rod.fuel()
print(string.format("%d min %02d s of fuel", math.floor(s / 60), math.floor(s % 60)))

See also reactor_fuel_acceptor.fuel()

#

rod.active()

→ boolean

Reactor Rod only. true while the rod has fuel: it glows, heats and gives off radiation. Only a burning rod explodes, when it overheats or when it is broken.

Returns
boolean
true while the rod burns
Brass
local rod = peripheral.find("reactor_rod")
print(rod.active(), rod.temperature())

See also heat_block.fuel()

#

vent.extracting()

→ number

Reactor Heat Vent only. The heat the vent took from its rods in the last second. It takes from each rod as much as it can hold, up to 10,000 ˚T in the vent: when the vent nears 10,000 ˚T, it takes nothing more and the rods heat up. Carry its heat away to keep it taking.

Returns
number
the heat the vent took from the rods in the last second, in ˚T
Brass
local vent = peripheral.find("reactor_heat_vent")
print(vent.extracting() .. " taken, vent at " .. vent.temperature())
#

acceptor.rods()

→ number⚙ cost 6

The rods in a straight line from the faces of the acceptor, as it finds them itself (up to 32 per line). 0 means it feeds nothing: check where it stands.

Returns
number
the number of rods the acceptor feeds
Brass
local acceptor = peripheral.find("reactor_fuel_acceptor")
print(acceptor.rods() .. " rods")

See also reactor_fuel_acceptor.fuel()

#

acceptor.fuel()

→ number⚙ cost 6

The fuel of its rods, in seconds: their mean, which is also what each one holds, since the acceptor shares the fuel every second. 0 without rods.

Returns
number
the mean fuel of its rods, in seconds; 0 without rods
Brass
local acceptor = peripheral.find("reactor_fuel_acceptor")
print(math.floor(acceptor.fuel() / 60) .. " min of fuel")

See also heat_block.fuel()

#

acceptor.temperature()

→ number⚙ cost 6

The temperature of the hottest of its rods: one call watches the whole reactor, even with no rod in reach of the computer. 0 without rods.

Returns
number
the temperature of its hottest rod, in ˚T; 0 without rods
Brass
local acceptor = peripheral.find("reactor_fuel_acceptor")
if acceptor.temperature() > 20000 then
  print("Too hot!")
end

See also heat_block.max_temperature()

A reactor guard

A complete program that runs a reactor with little fuel at a time, so that it goes out soon after the fuel stops. The fuel acceptor is on the left of the computer, a chest of Nuclear Fuel on the right, a lamp or a bell on top. Every second the computer reads the reactor. While the rods hold less than 2 minutes of fuel, it moves one Nuclear Fuel into the acceptor; at half the limit it stops feeding it, and from 75 % it sounds the alarm.

The rods then never hold much more than one Nuclear Fuel (24 minutes for one rod, shared among them all), instead of up to 4 h 48 min each when a funnel keeps the acceptor full. If the chest runs dry or the program stops, the reactor burns out by itself. The limit is the one of a rod with the default settings; read it from a rod with heat_block.max_temperature() when the server changes it.

Brass
local acceptor = peripheral.wrap("left")
local chest = peripheral.wrap("right")
local LIMIT = 26000   -- max_temperature() of a reactor rod, default settings
local LOW = 120       -- seconds of fuel left before adding more

while true do
  local hot = acceptor.temperature()
  local fuel = acceptor.fuel()
  local state = "running"
  if hot >= LIMIT * 0.5 then
    state = "too hot: no more fuel"
  elseif fuel < LOW and acceptor.count() == 0 then
    if chest.push("left", nil, 1) > 0 then
      state = "fuel added"
    else
      state = "out of fuel"
    end
  end
  rs.set("top", hot >= LIMIT * 0.75)

  term.clear()
  term.set_cursor(1, 1)
  print("REACTOR, " .. acceptor.rods() .. " rods")
  if hot >= LIMIT * 0.75 then
    term.set_fg(term.colors.red)
  elseif hot >= LIMIT * 0.5 then
    term.set_fg(term.colors.yellow)
  end
  print(string.format("hottest rod %d / %d", math.floor(hot), LIMIT))
  term.set_fg(term.colors.white)
  print(string.format("fuel %d min %02d s", math.floor(fuel / 60), math.floor(fuel % 60)))
  print(state)
  sleep(1)
end

acceptor.count() and chest.push come from Inventories: the acceptor takes only fuel, so the chest should hold nothing else.