Affects Version/s: 0.14.0, 0.14.0 Beta 7, 0.14.2, 0.15.6, 0.16.0, 0.16.1, 0.17.0.1, 0.16.2, 126.96.36.199, 188.8.131.52, 1.0.2, 1.0.3, 184.108.40.206, 220.127.116.11, 18.104.22.168, 22.214.171.124, 126.96.36.199, 188.8.131.52, 184.108.40.206, 220.127.116.11, 18.104.22.168, 22.214.171.124
Fix Version/s: 126.96.36.199
Platform:Phone - Android - LG G2
In my survival world, I have a lever that controls dispensers on a semi automatic wheat farm. The dispensers fire water buckets. I Have a circuit seen below which activates on the rising and falling action of the lever. When I am in the game, the circuit works as intended but if I relog the game (quit to title and join back) the dispenser will fire the bucket and stay in that state. I assume it is the Redstone torches that do not save state as I leave the game.
Upon loading a world, redstone components update. The redstone may change based on an unloaded chunk, causing it to turn off when it should be being powered by something in the unloaded chunk next to it. To reproduce: make a long line of redstone with repeaters, power one end, then stand at the other end and lower your render distance. Then reload the world. The redstone will turn off, then turn back on as you load the component powering it. This affects all redstone components that I am aware of, including pistons. It tends to break contraptions as one half may update while the other is unloaded, often sending redstone contraptions into a clock.
Steps to reproduce:
1. Create a flat creative world.
2. Place a lever, turn it on, and then place a long line redstone dust and repeaters extending far out some distance outside of chunk-loading range, and then make the wire do a u-turn and come back to the start. Make sure there are repeaters so that the signal can go all the way.
3. Exit the world and reload it.
4. Wait a little while, and you'll notice that the returning end of the wire will turn off, as the redstone updates and can't find a power source, since the connection between the start and end is unloaded, and also because of
MCPE-15779. (Though even if that was fixed there might still be a moment where the dust becomes unpowered while the chunks are still being loaded.)
This effect can also sometimes be seen in cases where a piston is being powered by a source in another chunk, and the chunk with the piston loads first. This is more difficult to reproduce in a world, though.
Edit by [MCPE Mod] PHO:
The second part of the original description is WAI:
The first part, redstone components being ticked upon loading chunks, is the real issue. It is probably a leftover from the past behavior: state of redstone components used to be forgotten upon unloading chunks, and in order to recover it the game ticked all of them on the chunk reload. Now their state seems to be correctly saved in the file so they need not to be ticked, and doing so also causes the very problem: components in unloaded chunks affect the entire contraption. To reproduce this,
- Open a world attached to
- Load all the chunks where the entire circuit resides in.
- Return to the point where the piston is placed.
- Close the world and open it again.
- Observe that the piston momentarily extends and then retracts. Ideally the piston and the line of dust should stay activated even though the middle part of the dust line is in unloaded chunks, because their last state (active) should be saved in the file and the game only needs to restore it.