This page documents the Extra Cells integration exposed to Lua by OpenComputers. It extends AE network-facing components with gas listing support.
- Dependency:
ec - Label:
integration-required
me_controllerme_interface
- Listing stored gases available through an Extra Cells AE network.
- Extending existing AE controller and interface automation with gas awareness.
When the ec integration is available, me_controller gains one additional gas-related callback.
- Syntax:
getGasesInNetwork(): table - Purpose: Return all gas stacks currently stored in the AE network.
- Returns:
- A Lua array of gas stack descriptor tables.
- Usage notes:
- Only fluid entries recognized by Extra Cells as gases are returned.
- This supplements the normal
appengnetwork inspection callbacks.
Block me_interface components also gain the same gas callback when backed by an Extra Cells-capable network.
- Syntax:
getGasesInNetwork(): table - Purpose: Return all gas stacks currently visible in the connected AE network.
- Returns:
- A Lua array of gas stack descriptor tables.
- Usage notes:
- This is most useful when your automation is already centered on interface blocks instead of controllers.
local component = require("component")
local me = component.me_controller
for _, gas in ipairs(me.getGasesInNetwork()) do
print(gas.label or gas.name, gas.amount)
endappengmekanism