Page 1 of 1
[boskid] [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Fri Nov 08, 2024 7:39 pm
by Hengo
Simplified steps to reproduce:
Build asteroid collector and fill it with some asteroids.
Connect asteroid collector to something that does not send a signal (like electric pole)
Enable "Set filters" and "Read contents". Then the collector filters for nothing.
Remove an asteroid from the collector, either by left clicking on items, or by using inserters.
In the tick that the item is removed the collector filters for the item that was removed. If there is an asteroid close it will collect it (in case of higher rarity it will collect many at once).
You can also see the filter icon flicker for one tick.
Possible workaround: Use a constant combinator with a negative signal of -2. The negative signal counters the "ghost" signal generated by removing an item.
My theory: The logic you have that prevents the signal from the content of the collector to affect the filter has 1 tick delay and causes some issues.
Gameplay issues caused by this: Circuit logic that limits the collector to collect asteroids if its inventory already has over X items will only work for normal rarity collectors. For anything above this bug causes the collector to gradually fill up with items never requested.
Re: [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Sun Nov 10, 2024 12:56 am
by mechatimer
Same issue here. Had to do the 'workaround' to make things work.
Re: [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Mon Nov 11, 2024 5:39 pm
by True.Boriska
I have the same problem.
My collectors filled with other chunks and there is no place left for promethium.
Re: [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Thu Nov 14, 2024 12:57 pm
by _Jay_
Experiencing the same issue here.
I'll try out that workaround, but would be great to see this issue addressed.
Re: [Hrusa][2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Fri Nov 15, 2024 10:42 pm
by spiral_power
I am also having trouble with this filter.
Re: [boskid][2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Sun Nov 17, 2024 11:52 pm
by boskid
Ok, after rewriting half of the asteroid collector control behavior code, copying pieces of logic from assembler control behavior, fixing assembler control behavior, writing tests for asteroid collector control behavior, fixing 2 other issues, verifying gui works correct, after about half a day of work by sunday i managed to fix this issue for 2.0.20. Now i hate the ignore-self-output behavior of asteroid collector but i have no alternatives for it.
Re: [boskid] [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Mon Nov 18, 2024 11:33 pm
by spiral_power
I admire your efforts.
Re: [boskid] [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Tue Nov 19, 2024 12:18 am
by sythys
Now i hate the ignore-self-output behavior of asteroid collector but i have no alternatives for it.
How about being able to set the network color we read and write to?
We could set the green network as output for content reading and use the red network for filter writing.
Kind regards
sythys
Re: [boskid] [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Tue Nov 19, 2024 12:15 pm
by Visione
sythys wrote: ↑Tue Nov 19, 2024 12:18 am
Now i hate the ignore-self-output behavior of asteroid collector but i have no alternatives for it.
How about being able to set the network color we read and write to?
We could set the green network as output for content reading and use the red network for filter writing.
Kind regards
sythys
I think this would be a solution to a broader scope of problems. I'm running into an issue with making a assembler that makes all qualities of the same product due to the same fundamental problem.
In my case I want to be able to set an assembler recipe and I also read the content of that same assembler. I want to read the content in combination with the content of the inserter and a chest, to detected if I have enough items of a certain quality to make an item with the same quality. Because I can't set "set recipe" from the red circuit network, and I can't set "read content" from the green circuit network I need to jump through a couple of hoops to achieve this.
First of all I need to make a arithmetic combinator (that acts like a diode) so the contents of the inserter and the chest don't "pollute" the signals send to the assembler. If I don't do this the assembler tries to make whatever is in the chest or inserter.
This causes a new problem, the arithmetic combinator (that acts like a diode) takes a game tick to compute its output, items that would have been content of the assembler, will vanish for a split second. Invalidating the check which quality item I'm trying to make. If unresolved, the assembler will first be set with a recipe, it will then be loaded with items, then the items disappear from the network for a brief second, the recipe will be unset, and the assembler will be unloaded again. Then all the items are available again on the network, and rinse and repeat. This will make the contraption hang in a loop, never building anything.
I fixed this by including a SR-latch. Which makes it all work, but that's a lot of extra complicated logic, and a few extra combinators. It took me quite some while to debug this all out, I think most people would have never figured out. That's a lot of extra complications just because we can't "read content" to circuit network A, and "set recipe" from circuit network B.
Re: [boskid] [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Tue Nov 19, 2024 4:22 pm
by Muche
The ability to configure which wire an entity reads from/writes to its various capabilities is the topic of
117481 Please, PLEASE make circuit connection behavior configurable per wire and might be addressed in a future version 2.1.
Re: [boskid] [2.0.15] Asteroid Collector circuit filter not working one tick after item removed
Posted: Wed Nov 20, 2024 8:33 pm
by sythys
Nice! didn't know people are on it. I guess we wait for 2.1 then.