From f1a7f10f500535202eea04276069d3ae36d5694b Mon Sep 17 00:00:00 2001 From: austin Date: Mon, 28 Apr 2025 13:00:17 -0400 Subject: [PATCH] Area selection radius fix --- .../client/interact/select/AreaSelection.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/main/java/electrosphere/client/interact/select/AreaSelection.java b/src/main/java/electrosphere/client/interact/select/AreaSelection.java index 857750ca..46ea6175 100644 --- a/src/main/java/electrosphere/client/interact/select/AreaSelection.java +++ b/src/main/java/electrosphere/client/interact/select/AreaSelection.java @@ -153,6 +153,15 @@ public class AreaSelection { increment++; } + //loops only break on the iteration where we encounter a barrier, so need to roll the radius values back by 1 + //in order to not include the blocks that caused the break itself + if(radEnd > 1){ + radEnd--; + } + if(radStart < 0){ + radStart++; + } + Vector3d startPos = new Vector3d(Globals.clientWorldData.convertBlockToRealSpace(chunkPos, blockPos)) .add( radStart * BlockChunkData.BLOCK_SIZE_MULTIPLIER,