mojira.dev
MC-202675

Sound/visuals difference when shooting through "air" between stairs/bottom slap and water on top

Short

With short passages under (floating) water, arrows may or may not make a splash sound depending on the distance from which the shot was made. Longer passages will always make the splash sound. In all cases, the arrow does not visibly touch the floating water block.

Longer

Test setup:

Have pool of water (source blocks) above a "floor" made of bottom slabs or upright stairs blocks. This leaves a visual air gap (of half a block height) between the water blocks and the slabs/stairs, either wide flat open gap with bottom slabs, or narrow tunnels with stairs.

Or download the attached world save with a suitable test setup and instructions.

Test action:

Shoot arrows horizontally through those gaps, so that the arrow does not hit the slabs/stairs or the water blocks.

Current results:

If the player is at certain distances and the length of the gap (in shooting direction) is short enough, there is no splash sound.

But if the player moves to another distance (e.g. about 1 block further away), or the gap is long enough, there will be splash sound(s), even if the arrow doesn't touch water.

Expected results:

One would expect water to flow down to fill the free space in the block/stair block's space, and thus arrows to make sounds. However, at least visually the water does not flow down, and thus shooting arrows through should not make sounds.

Or, very least, the sounds should or should not be played consistently, not depend on how long "air gap tunnel" to fly through, and especially not depend on how far away the player was from the gap.

Perhaps...

... The splash sound could be triggered by a larger hitbox of the arrow touching the water above, but the hitbox collision is checked only at specific intervals, and during its flight, a fast arrow might be at first just before the water, and at the next step already passed the water, thus not triggering the splash sound. With a longer gap/passage, those hitbox checks would always "hit" some of the water blocks above the path.

 

(As of 22w17a, attached a world save with test setup. A superflat with "test range" and instructions.)

Linked issues

Attachments

Comments

violine1101

Are you sure the arrow hitbox doesn't intersect the water at all? You can enable F3+B to check.

bugi74

In short: difficult to see if the fly-time-hitbox touches water, but judging from the tests, the hitbox stuff would not even explain the results.

Longer:

Hard to tell; there is too much particles in the way (and difficult to stop at just the right moment). Looks like once the arrow stops, the hitbox is half block height/width/length (cube), so presumably it would touch either the wood block below or the water (or glass) above, but there is big enough range of vertical aims where it does not stick to anything, so obviously the on-the-fly "hit" box is much smaller than that.

While testing more with the hitbox view enabled, I noticed that going further away, maybe 5-6 blocks, there is another distance where the arrow can easily pass through without making splash sound. (I had an idea that maybe the arrow gets somehow "active" only after one block away or something, which would have allowed the near shots to pass through without splash, but considering both the fact that arrow can hit the wood right in front of the player and the silent passes from longer distances, that does not seem to be a valid explanation.)

In any case, after shooting around 100 arrows at different distances and slightly different aims, it is clear (to me) that at suitable distances, it is possible to get the arrow through the gap consistently without splash sound (just have a decent aim), yet at some other distances it seems to be nearly impossible (no matter how many slightly differently good aims through the gap is tried). If the arrow's on-the-fly hitbox would explain the sounds, the sounds should be happening at all shooting distances roughly equally (or slightly more from further away, see below), which is not the case.

For example, at certain distance (around 5ish blocks), aiming (about) horizontally straight through (about) middle gives either consistent splashing, or by moving half a block away (without changing the aim at all), consistently no splashing.  Still at that slightly further distance, aim a tiny bit up and still no splash, move back the half a block forward, and it makes a splash again. I kept testing this while moving back and forth, the result is quite repeatable. Considering how the angles work, the shots from longer distance will have larger vertical spread by the time they are under the water, so they should be "touching" the water more often than when shooting closer. With this particular test case, the opposite was observed.

[Mod] markderickson

I'm unable to reproduce this issue – if this is still an issue for you, could you please attach a video?

bugi74

I can still reproduce.

A video would be challenging currently... would a world save with nice instructions do?

Eometheous

@Markku, if you are on windows, you might have the XBOX Game Bar App. You can record a short 30 second clip with by pressing the windows key and G at the same time and then click on the record last 30s button on the top left. Or you can press the window key, alt key, and G at the same time.

Brain81505

Is this still an issue in 1.19.4?

[Mod] Jingy

This issue may be either invalid, or working as intended. With the recently added /tick command, you can freeze the game and observe exactly how the arrow is behaving.

With my testing, here are my two reasonings for supoorting it being invalid, or working as intended:

  1. The arrow makes a sound in the first place as it does actually collide with the water. Despite not being entirely apparent to the player as the arrow model itself is smaller than it's hitbox, the arrow comes into contact as shown:

    [media]
  2. The arrow doesn't always collide with the water simply due to the travel time of arrows / how often their position is updated. Their position is not updated every tick, so when fired from different distances, sometimes they will not be ticked when underneath the water, as shown:

[media]
migrated

The second point would actually be a reason to mark this as duplicate of MC-92875. As for the first point, I guess MC-156685 best describes that part.

Duplicate of MC-156685 and MC-92875.

[Mod] Jingy

Agreed, thank you for finding those.

bugi74

... As I thought as a possible reason in the "Perhaps..." paragraph.

Although, that still leaves a bit of discrepancy between the shown hitbox size (and how it makes a sound without arrow visibly touching water), and when it hits solids (can get pretty close to them without the arrow stopping).  But, I guess that would best be a separate ticket after/if the tick-rate -related part gets fixed.  This one ended up listing 3 "weird things" in one ticket 😛

Oooh, only now watched that video.. the arrow isn't centered in the hitbox.. weird, but explains the doesn't hit solid, but makes sound -thing.

bugi74

(Unassigned)

Unconfirmed

(Unassigned)

1.16.4 Pre-release 2, 22w17a

Retrieved