For example, I'm requesting carbon from my space platform over Gleba. When there's no carbon in the logistic system, all the graphic displays are blank. When there is carbon, the roboport sends a signal of how many carbon are there. If there's 0 carbon, no signal is sent. (it's also connected to an inventory bar graph, but that's not necessary for this question.)
Roboport -> decider (* in, carbon out) -> display (*>=0, show*)
When carbon = 0, that display is blank. When carbon >0, then it shows carbon. I always want it to show carbon.
I could put a constant combinator in there, but then I'd have to set both it and the decider, but it seems inelegant.
Roboport, constant(carbon @ 1) -> decider (* in, carbon out) -> display (*>=0, show*)
That would work, because carbon will always be 1, but again it seems inelegant, and this game is all about elegant solutions.
Another example is when requesting things from the space platform. I have the roboport tell me how much carbon I have, multiply by negative 1, add that to the limit I want and then request that from the space platform. If I have 1000 carbon, *-1 is -1000, +5000=4000, so it's requesting 4000 carbon from the platform. When that is 0, it doesn't request anything. Since I'm using * to pass the carbon value thru the decider, when the value is 0, there's no signal sent.
Roboport -> decider (* in, carbon out) -> mult -1 -> add 5000 -> request that from platform.
Again, I can put a constant at 1 carbon and it works, but again, inelegant.
Is there a better way to pass the identity of carbon thru with a value of 0? (Because value 0 defaults to essentially "null" or "none" and doesn't pass the carbon item thru.
Is there a way to have a value always, even when logistics = 0?
-
- Fast Inserter
- Posts: 241
- Joined: Wed Mar 02, 2016 10:09 pm
- Contact:
Re: Is there a way to have a value always, even when logistics = 0?
Use this combinator
it gives a 1 signal if the Red signal line has values with this signal and no value on the green signal line.
You can use a constant combinator with a signal list or the pre calculation values for the red input.
it gives a 1 signal if the Red signal line has values with this signal and no value on the green signal line.
You can use a constant combinator with a signal list or the pre calculation values for the red input.
English is my second language and I am not good at languages