[2.0.10] Selector Combinator "Select Index" mode is difficult to use with signal-based index
Posted: Thu Oct 24, 2024 5:06 pm
The Selector Combinator's "Select Index" mode picks a signal out of the input signals using an index to determine which signal to select. Normally, this index is the constant 0, but you can also use an input signal as the index. This causes a problem though, because now your "index signal" is now part of the list of signals that the combinator is selecting from!
I'm using this feature as part of an automatic crafting "Automall", and I have a chain of "Automall Modules" where each module gets an increasing index. (The "I" signal in the screenshot.) This signal is moduloed with the signal count, so each module works on one recipe in the list of requests. Because the modules don't actually care about what the size of the signal is, I was able to avoid this problem in my circuit by increasing the value of my requests by 1000000, but this feels like a dirty trick.
I think the Selector Combinator, or at least certain modes of it like Select Index, should be able to filter which wires they are operating on, like the other combinators are able to now. That way the combinator can receive a clean list of signals on one wire, and the index signal on the other wire. Quality Transfer is another mode that might benefit from this separation, but I haven't had a reason to use that mode yet.
Screenshot of the issue:
(I'm still sorting out some bugs in the design [like "I" is supposed to be 1 there and "C" should not be present,] but this issue stood out to me, as there didn't seem to be an obvious way around it besides the trick I mentioned above.)
I'm using this feature as part of an automatic crafting "Automall", and I have a chain of "Automall Modules" where each module gets an increasing index. (The "I" signal in the screenshot.) This signal is moduloed with the signal count, so each module works on one recipe in the list of requests. Because the modules don't actually care about what the size of the signal is, I was able to avoid this problem in my circuit by increasing the value of my requests by 1000000, but this feels like a dirty trick.
I think the Selector Combinator, or at least certain modes of it like Select Index, should be able to filter which wires they are operating on, like the other combinators are able to now. That way the combinator can receive a clean list of signals on one wire, and the index signal on the other wire. Quality Transfer is another mode that might benefit from this separation, but I haven't had a reason to use that mode yet.
Screenshot of the issue:
(I'm still sorting out some bugs in the design [like "I" is supposed to be 1 there and "C" should not be present,] but this issue stood out to me, as there didn't seem to be an obvious way around it besides the trick I mentioned above.)