The Bug:
Channeling doesn't affect mobs in some circumstances, here's a list of what i tested:
|
|
|
|
soul sand | not struck by lightning bolt |
|
|
|
|
snow | not struck if snow layers is 8 |
Mob in a boat | not struck by lightning bolt. This doesn't affect passive mobs. |
Mob in a minecart | not struck by lightning bolt. This doesn't affect passive mobs. |
Honey block | not struck by lightning bolt |
Inside a cobweb | not struck by lightning bolt |
Inside lava | not struck by lightning bolt |
Inside water | not struck by lightning bolt |
Inside Powder Snow | not struck by lightning bolt |
Note: Mobs riding horses are not affected.
Linked issues
relates to 2
Attachments
Comments 19
I'm thinking maybe the game uses the lighting subroutine to check for sky access?
Apart from the boat the blocks where lightning doesn't strike seem to be the ones where F3 reports 0 light.
Boats on land do have 0 light though, and a boat in water possibly counts as being in water.
Boats in water only have 14 sky light which isn't full sky access.
Mobs in lava aren't struck by lightning either, also 14 sky light.
I would assume the cause of this bug (as well as MC-125773 and MC-217528) to be that Channeling checks for sky exposure at a mob's feet level. So when mobs are standing on non-full blocks that block sky light, their feet technically don't have sky access, therefore Channeling doesn't work. Similarly, when mobs are riding boats/minecarts, their hitboxes extend below the bottom of the vehicles, observable using F3 + B. Hopefully someone can do a code analysis on this, so my speculation can be confirmed.
Sounds like the thurderstorm is going to the top of the block only, but if the mob is slightly lower than that, it doesnt hit it