The onRedstoneUpdate scripting block hook is triggered erroneously when blocks using the hook are loaded. This occurs when blocks are first placed and when loading chunks including the affected blocks.
This hook should not trigger in loading-related scenarios and should only fire when the redstone power on a block is actually updated.
Demonstration
The below video demonstrates this bug by firing a log whenever the hook would be invoked:
It’s only visible for a frame, but a log is emitted on world load. Later, this hook is shown to fire when placing a custom block utilizing it.
Reproduction
This example is taken from the behavior pack in the following world attached for convenience:
This world can be opened (in Minecraft Preview) for inspection or unzipped to access the code associated with such. Ensure that the content log is enabled before opening the world.
Attachments
Comments 0
No comments.