Page 1 of 1

[1.1.105] Mods can set special signals (undefined behavior)

Posted: Fri Mar 22, 2024 4:08 pm
by BinarySpike
My mod is able to set special signals (anything, each, everything) on Inserter Control Behavior settings—even though those signals are not provided in the UI.

Typically, I expect a lua exception to be generated.

This is the offending code:

Code: Select all

cb.circuit_stack_control_signal = updateSignal(cb.circuit_stack_control_signal or {}, settings)
Where `updateSignal` returns one of the special signals.

See the image below:
Image

Re: [1.1.105] Mods can set special signals (undefined behavior)

Posted: Fri Mar 22, 2024 7:21 pm
by Rseding91
Technically speaking nothing breaks by setting them. Simply they don’t do anything special for inserters. They are simply treated special in places they get allowed.