Specify extra layer of "parameters={}" in ConstantCombinatorParameters
Posted: Tue Aug 25, 2020 10:37 pm
https://lua-api.factorio.com/latest/Lua ... avior.html says that LuaConstantCombinatorControlBehavior.parameters is of type ConstantCombinatorParameters, and https://lua-api.factorio.com/latest/Con ... Parameters says it should be "an array of tables ..."
However, there is an extra layer hidden in there that is only documented in an example elsewhere, at https://lua-api.factorio.com/latest/Lua ... parameters
Namely, the contents of LuaConstantCombinatorControlBehavior.parameters is not an array, it is {parameters=the_array}, so the place you encounter the documented structure of ConstantCombinatorParameters is not at LuaConstantCombinatorControlBehavior.parameters but at LuaConstantCombinatorControlBehavior.parameters.parameters.
Given the age of this behavior I doubt it's to be considered a bug, so this is just a request to clarify the documentation.
However, there is an extra layer hidden in there that is only documented in an example elsewhere, at https://lua-api.factorio.com/latest/Lua ... parameters
Namely, the contents of LuaConstantCombinatorControlBehavior.parameters is not an array, it is {parameters=the_array}, so the place you encounter the documented structure of ConstantCombinatorParameters is not at LuaConstantCombinatorControlBehavior.parameters but at LuaConstantCombinatorControlBehavior.parameters.parameters.
Given the age of this behavior I doubt it's to be considered a bug, so this is just a request to clarify the documentation.