forked from virt-mirrors/Sit
check the block below if occupied
This commit is contained in:
parent
8012f81e46
commit
012778ba2b
2 changed files with 8 additions and 8 deletions
|
@ -58,10 +58,7 @@ public class Utl {
|
|||
* checks the list of sit entities and sees if any of them are occupying the block pos
|
||||
*/
|
||||
public static boolean isNotOccupied(BlockPos pos) {
|
||||
for (DisplayEntity.TextDisplayEntity entity : Data.getSitEntities().values()) {
|
||||
if (entity.getBlockPos().equals(pos)) return false;
|
||||
}
|
||||
return true;
|
||||
return Data.getSitEntities().values().stream().noneMatch(entity -> entity.getBlockPos().equals(pos));
|
||||
}
|
||||
|
||||
public static class Num {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue