The bug
Redstone wire in some situations uses different logic for connecting visually (in which direction the dust texture goes) and logically (what gets powered).
Affected situations
List might be incomplete
Last updated for 18w05a
Situation | Looks like | Is actually | Screenshot |
---|---|---|---|
Redstone wire connecting upwards to slab / stairs / glowstone | line | dot | [media] |
â Glowstone should possibly not show redstone wire on its side since all other blocks which only transfer a redstone signal upwards have no wire on their side.
Code analysis and suggested fix
See comment
Linked issues
is duplicated by 23
relates to 6
Attachments
Comments 58
It's the same with glowstone and slabs i think.
both redstone pieces would be points, because they are disconnected by the leaves. But because redstone automatically attaches to the torch it will turn into a line. Even without leaves and further redstone the redstone next to the lamp would turn into a line.
We will see what will happen with redstone when jeb rewrites the whole thing. DOn't expect this to be fixed before 1.5
Vanilla:
Glowstone should possibly not show redstone wire on its side since all other blocks which only transfer a redstone signal upwards have no wire on their side.
This seems WAI because there is a check specifically just for glowstone
(The check was merged with isFaceSturdy() in 1.13)
Other blocks like observers and pistons now have redstone visually running up the side too
Slabs don't have a solid face on the side so it doesn't show the vertical redstone
Â
Visual Fix:
Change the direction redstone visually faces matching the logical direction
Code to change is in RedstoneWireBlock.java under getConnectingSide();
Currently, it checks if the block next to the dust is isFaceSturdy() OR HopperÂ
Then checks if the block is isCollisionShapeFullBlock() returns upwards if true else side if false
To change the visual, this should be changed to if isRedstoneConductor() connect Upwards
This is to be more consistent with isPowerSourceAt()
This has a side effect that redstone won't show visually on the side of non-isRedstoneConductor() blocks
Â
Â
Logical Fix:
Change the direction of dust logically to match vanilla visuals
Code to change is in RedstoneWireBlock.java under isPowerSourceAt();
Currently it checks if the block next to the dust is isRedstoneConductor() and the block above is not isRedstoneConductor() then calls shouldConnectTo()
The check for if the block to the side is isRedstoneConductor() should be changed to isFaceSturdy() OR Hopper
This is to be more consistent with getConnectingSide();
20w12a
[media]Redstone(unpowered) present, all go up
[media]
Redstone not present, only middle goes up
adding the redstone after the fact doesnt make the pistons go up either
@urielsasis After investigation it seems that your bug is MC-9405
Related, but resolved as won't fix.
The "â Â Glowstone should possibly not show redstone wire on its side since all other blocks which only transfer a redstone signal upwards have no wire on their side." is no longer true, redstone blocks and glass both show the redstone going up the sides
This has been fixed in 20w18a.
https://www.minecraft.net/en-us/article/minecraft-snapshot-20w18a
But with Glowstone and Leaves there's no Redstone on the side of the upper block. If you put there glass instead of the Leaves it's connected on the side, so I don't think it's a feature... AND: It's shown as a redstone-point, but it still works as a redstone-line.