Skip to content

Commit

Permalink
NewBlockCompat - fix issue with bisected blocks alternatively placing (
Browse files Browse the repository at this point in the history
…#3703)

- By not cloning the data, the original data is set to the opposing state (up/down), therefor placing the next block starts with the opposing state
  • Loading branch information
ShaneBeee authored Mar 21, 2021
1 parent d822fe5 commit 209bcbf
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ public void setBlock(Block block, Material type, @Nullable BlockValues values, i
if (Bed.class.isAssignableFrom(dataType)) {
Bed data;
if (ourValues != null)
data = (Bed) ourValues.data;
data = (Bed) ourValues.data.clone();
else
data = (Bed) Bukkit.createBlockData(type);

Expand Down Expand Up @@ -229,7 +229,7 @@ public void setBlock(Block block, Material type, @Nullable BlockValues values, i
if (Bisected.class.isAssignableFrom(dataType) && !Tag.STAIRS.isTagged(type) && !Tag.TRAPDOORS.isTagged(type)) {
Bisected data;
if (ourValues != null)
data = (Bisected) ourValues.data;
data = (Bisected) ourValues.data.clone();
else
data = (Bisected) Bukkit.createBlockData(type);

Expand Down

0 comments on commit 209bcbf

Please sign in to comment.