'Each on Red Circuit' and 'Each on Green Circuit'

Post your ideas and suggestions how to improve the game.

Moderator: ickputzdirwech

Post Reply
Clockulator
Manual Inserter
Manual Inserter
Posts: 2
Joined: Thu Jan 21, 2021 12:44 am
Contact:

'Each on Red Circuit' and 'Each on Green Circuit'

Post by Clockulator »

TL;DR
Allow combinator and comparator to use 'Each on Red Circuit' and 'Each on Green Circuit' on the left and right sides of operand. (Where 'Each on Red Circuit' and 'Each on Green Circuit' would be new features). This would allow operations to be performed on multiple item types signalled on a circuit, between two circuits.
What ?
Add 'Each on Red Circuit' and 'Each on Green Circuit' to allow logic and mathematical expressions on several item counts signalled on one circuit. Allowing comparisons and operations between multiple values between two circuits. Only items of the same type would interact between the two sides of the operation (implementation would be like 'Each', but allow an operand to interact with items of the same type on the second circuit).

EG:
- Input Green: 50 Copper Plate, 500 Coal, 10 Wood
- Input Red: 1 Copper Plate

- Equation: "Each Green" * "Each Red"

- Output 'Each': 50 Copper Plate (can be attached to output Red, Green, or both networks).

Might look something like:
red_green.png
red_green.png (200.03 KiB) Viewed 1801 times
Why ?
It would allow the more traditional use of logic and mathematical expression on several item counts signalled on one circuit network. Allowing comparisons and operations between multiple values between two circuit networks.

To do this currently many individual comparators or combinators are needed (unless I've missed something), and knowledge at each comparator/combinator about which items types are you looking at. If you have 10s of different item types in your circuit network and want them all involved in the calculations, it’s a lot of blocks to put down and configure individually (and you might need to leave space in your layout to expand it with more item types later). Also for compute load (for mega bases) it would be more effect to be able to do this calculations in one entity.

User avatar
NotRexButCaesar
Smart Inserter
Smart Inserter
Posts: 1120
Joined: Sun Feb 16, 2020 12:47 am
Contact:

Re: 'Each on Red Circuit' and 'Each on Green Circuit'

Post by NotRexButCaesar »

+1 this would also make multiplying by stack size easier
—Crevez, chiens, si vous n'étes pas contents!

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: 'Each on Red Circuit' and 'Each on Green Circuit'

Post by ssilk »

This is an extended copy of similar requests from here
viewtopic.php?p=526422#p526422

Nearly same:

viewtopic.php?f=6&t=32300 Pairwise multiply/divide EACH signal in combinators
viewtopic.php?f=6&t=26944 Expand Circuit Network's "Each"
viewtopic.php?f=6&t=24257 New Combinator to work on wires seperatly
viewtopic.php?f=6&t=92616 filter combinator

viewtopic.php?f=80&t=50283 Separated Handling of Red and Green Wires
viewtopic.php?f=6&t=49278 circuit combinators, set wire-colors for select-windows
viewtopic.php?f=6&t=31438 Wire color based signal input selector (for virtual signals)


Similar:

viewtopic.php?f=6&t=61557 New combinator symbols: Each[Green] and Each[Red]
viewtopic.php?f=6&t=75852 One Wire for control circuits, colours as channels
viewtopic.php?f=6&t=56890 Separate signals to/from red and green wires
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

Clockulator
Manual Inserter
Manual Inserter
Posts: 2
Joined: Thu Jan 21, 2021 12:44 am
Contact:

Re: 'Each on Red Circuit' and 'Each on Green Circuit'

Post by Clockulator »

Thanks for pointing them out. I did have a little search but my skills where weak. My post is pretty much a duplication of the request in viewtopic.php?f=6&t=49278 with slightly different use case to demonstrate it.

All of these do show there is interest in something similar. Would be great to see something added to allow the red/green to be used as the left and right sides of expressions.

ichVII
Long Handed Inserter
Long Handed Inserter
Posts: 98
Joined: Mon Feb 27, 2017 10:16 pm
Contact:

Re: 'Each on Red Circuit' and 'Each on Green Circuit'

Post by ichVII »

Clockulator wrote:
Thu Jan 21, 2021 12:56 am
[...]
Why ?
It would allow the more traditional use of logic and mathematical expression on several item counts signalled on one circuit network. Allowing comparisons and operations between multiple values between two circuit networks.

To do this currently many individual comparators or combinators are needed (unless I've missed something), and knowledge at each comparator/combinator about which items types are you looking at. If you have 10s of different item types in your circuit network and want them all involved in the calculations, it’s a lot of blocks to put down and configure individually (and you might need to leave space in your layout to expand it with more item types later). Also for compute load (for mega bases) it would be more effect to be able to do this calculations in one entity.
A componentwise comparison can be achieved by just multiplying the red wire with -1 in a combinator, then wiring this and the green wire to a decider combinator.

A componentwise multiplication can be achieved by using the componentwise square function that exist in the game. You only need to calculate ((R+G)^2-R^2-G^2)/2. This should be possible in about 6 combinators (i have a blueprint somewhere, if you are interested). So you have kind of missed something.

Edit: blueprint. Its just 5 arithmetic combinators.

gGeorg
Filter Inserter
Filter Inserter
Posts: 392
Joined: Wed Jun 19, 2019 8:06 pm
Contact:

Re: 'Each on Red Circuit' and 'Each on Green Circuit'

Post by gGeorg »

What about make a selection of signal type for both inputs. Red/Green/All. Default is All. Then you can specifiy the wire for any operation you want.
e.g. for each input off any combinator you select a signal and type of signal. flexible and it do not brake any off current circuitry becose they are all set : signal to All.

You know yo need switch All not Both, becouse moders will want add dozen other colored wires. :twisted:

Post Reply

Return to “Ideas and Suggestions”