Project Red's Comparator does not match Vanilla behavior when signal strength output would be greater than 15
kitlith opened this issue · 5 comments
If someone manages to obtain a stack of non-stackable items (#1377), then a comparator can calculate a signal strength of greater than 15 (for vanilla Redstone). In this case, the vanilla comparator saturates -- it stays at 15 ss (what actually happens is that Redstone dust itself caps the ss, it'll transfer to other comparators), while the project red comparator wraps around.
(If you're wondering what's up with the numbers on the redstone dust, that's from a resource pack)
Okay, I have no idea what's going on here.
Seems there's also a difference between vanilla comparator powering red alloy wire and the project red comparator powering red alloy wire in this type of edge case? The multimeter says vanilla is giving the wire 33 ss, while project red is giving the wire 17 ss.
That's fair. I think mainly pointed it out because "red power comperator is basically a vanilla comparator except you can place it on walls" -- think I saw that on the wiki or something.
It is. But this is outside of normal conditions and it’s undefined behavior when the signal is more than 15. And this is caused by the core foundation of how PR logic gates calculate power. Not worth changing over this.
I've adjusted the comparator as much as possible to act more like the vanilla comparator in 64ab50e. It doesn't fix this specific case though, but since this is only relevant when you have invalid items, I'm not too concerned.