Blockmask onlyair attribute includes all non-occluding blocks

Summary

Even with onlyair set to true in blockmask, blocks such as glass and stained glass will also be masked. The documentation specifies it is only air, but that just isn't the case.

Steps to reproduce

Call blockmask with onlyair set to true, create a sphere around current location and have the floor made of stained glass

Current behavior

The non-air blocks are masked

Intended correct behavior

The non-air blocks are not masked

Proposed fixes

Change logic in BlockMaskEffect.java to match other classes that use MaskEffect.ONLY_AIR

BukkitAdapter.adapt(newloc).getBlock().getType() == Material.AIR or block.getType().isAir()

instead of

!newloc.getBlock().getType().isOccluding()

Edited Feb 23, 2024 by Mykindos
Assignee Loading
Time tracking Loading