I wrote myself a quick fix, seems to be working with smoke tests and my current save. See the diff below, I didn't manage to create a github account for sending a real pull request
--- XXX\mods\Merge_Signals_Combinator_1.0.4\prototypes\merge-signal-combinator.lua.bak
+++ XXX\mods\Merge_Signals_Combinator_1.0.4\prototypes\merge-signal-combinator.lua
@@ -20,10 +20,13 @@
if not red_data or not green_data then
return
end
+
+ local output_signal_index = 1
for i,signal_data in pairs(red_data.signals or {}) do
signal_data.count=green_data.get_signal(signal_data.signal)*signal_data.count
if signal_data.count~=0 then
- self.sender.get_or_create_control_behavior().set_signal(i,signal_data)
+ self.sender.get_or_create_control_behavior().set_signal(output_signal_index,signal_data)
+ output_signal_index = output_signal_index + 1
end
end
end
function msc_prototype:on_removed()
self.sender.destroy()
end
\ No newline at end of file