I'm trying to use luaTrain.insert_fluid and luaTrain.remove_fluid.
The documentation for luaTrain isn't helping me. The insert_fluid doesn't have the parameter documented... https://lua-api.factorio.com/latest/Lua ... sert_fluid
(version 0.17.79)
I've tried passing in a fluid array to insert_fluid / remove_fluid of this form
{ type="steam", amount=42 }
But I get a bad argument #3. Something about expecting a string and getting a nil. What string is needed?
Any ideas?
Documentation extract (0.17.79):
remove_fluid(fluid) → double
Remove some fluid from the train.
Parameters
fluid: A table with type and amount
Return value
The amount of fluid actually removed.
insert_fluid(fluid) → double
Inserts the given fluid into the first available location in this train.
Parameters
Return value
The amount inserted.