Repository navigation
Count water-holding blocks in the 26.1+ fluid count - #1616
Merged
Merged
Conversation
booky10
approved these changes
Oct 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
isFluid only counts water, lava and waterlogged blocks, but bubble_column, kelp, kelp_plant, seagrass and tall_seagrass always hold water without a waterlogged property (went through getFluidState on every block in 26.3, those 5 are the only ones). Chunk_v1_18.set uses isFluid for the 26.1+ fluid count, so when soul sand turns water into a bubble column the count goes down 1 per block, and a section where the only fluid is a bubble column ends up at 0. Vanilla counts anything with a non-empty fluid state (LevelChunkSection.setBlockState), so the count the server sends with the chunk is right and it drifts from there
Grim skips water for sections with a fluid count of 0, so 26.x players in a bubble column get predicted as if they were in air (GrimAnticheat/Grim#2726, GrimAnticheat/Grim#2828). Soul sand column with vanilla 26.3 clients, standing still or swimming up, 3 runs each: grim 2.0 flags Simulation 37-41 times in 4 seconds on every run. Same grim built against this: 0/6. The same column on stone is 0/6 either way
ChunkFluidCountTest fails on 2.0 at the bubble column (count drops to 0) and passes with this, rest of the api tests pass too