From 8d211cfe381ff3679b94a9e5edccbed01660a1c5 Mon Sep 17 00:00:00 2001 From: dordsor21 Date: Thu, 27 Jun 2024 12:10:01 +0100 Subject: [PATCH] Cleanup --- .../v1_19_R3/PaperweightServerLevelDelegateProxy.java | 2 +- .../v1_20_R1/PaperweightServerLevelDelegateProxy.java | 2 +- .../v1_20_R2/PaperweightServerLevelDelegateProxy.java | 2 +- .../v1_20_R3/PaperweightServerLevelDelegateProxy.java | 2 +- .../v1_20_R4/PaperweightServerLevelDelegateProxy.java | 2 +- .../core/extent/processor/PlacementStateProcessor.java | 8 ++++---- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/worldedit-bukkit/adapters/adapter-1_19_4/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_19_R3/PaperweightServerLevelDelegateProxy.java b/worldedit-bukkit/adapters/adapter-1_19_4/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_19_R3/PaperweightServerLevelDelegateProxy.java index 3d656d33e..9a06254e7 100644 --- a/worldedit-bukkit/adapters/adapter-1_19_4/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_19_R3/PaperweightServerLevelDelegateProxy.java +++ b/worldedit-bukkit/adapters/adapter-1_19_4/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_19_R3/PaperweightServerLevelDelegateProxy.java @@ -104,7 +104,7 @@ public class PaperweightServerLevelDelegateProxy implements InvocationHandler { return null; } BlockEntity newEntity = tileEntity.getType().create(blockPos, getBlockState(blockPos)); - newEntity.load((CompoundTag) adapter.fromNativeBinary(this.editSession.getFullBlock( + newEntity.load((CompoundTag) adapter.fromNativeLin(this.editSession.getFullBlock( blockPos.getX(), blockPos.getY(), blockPos.getZ() diff --git a/worldedit-bukkit/adapters/adapter-1_20/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_20_R1/PaperweightServerLevelDelegateProxy.java b/worldedit-bukkit/adapters/adapter-1_20/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_20_R1/PaperweightServerLevelDelegateProxy.java index 0b5036656..6e15b8ce8 100644 --- a/worldedit-bukkit/adapters/adapter-1_20/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_20_R1/PaperweightServerLevelDelegateProxy.java +++ b/worldedit-bukkit/adapters/adapter-1_20/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_20_R1/PaperweightServerLevelDelegateProxy.java @@ -104,7 +104,7 @@ public class PaperweightServerLevelDelegateProxy implements InvocationHandler { return null; } BlockEntity newEntity = tileEntity.getType().create(blockPos, getBlockState(blockPos)); - newEntity.load((CompoundTag) adapter.fromNativeBinary(this.editSession.getFullBlock( + newEntity.load((CompoundTag) adapter.fromNativeLin(this.editSession.getFullBlock( blockPos.getX(), blockPos.getY(), blockPos.getZ() diff --git a/worldedit-bukkit/adapters/adapter-1_20_2/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_20_R2/PaperweightServerLevelDelegateProxy.java b/worldedit-bukkit/adapters/adapter-1_20_2/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_20_R2/PaperweightServerLevelDelegateProxy.java index e97c2d9c9..b2d946f1c 100644 --- a/worldedit-bukkit/adapters/adapter-1_20_2/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_20_R2/PaperweightServerLevelDelegateProxy.java +++ b/worldedit-bukkit/adapters/adapter-1_20_2/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext/fawe/v1_20_R2/PaperweightServerLevelDelegateProxy.java @@ -104,7 +104,7 @@ public class PaperweightServerLevelDelegateProxy implements InvocationHandler { return null; } BlockEntity newEntity = tileEntity.getType().create(blockPos, getBlockState(blockPos)); - newEntity.load((CompoundTag) adapter.fromNativeBinary(this.editSession.getFullBlock( + newEntity.load((CompoundTag) adapter.fromNativeLin(this.editSession.getFullBlock( blockPos.getX(), blockPos.getY(), blockPos.getZ() diff --git a/worldedit-bukkit/adapters/adapter-1_20_4/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext.fawe/v1_20_R3/PaperweightServerLevelDelegateProxy.java b/worldedit-bukkit/adapters/adapter-1_20_4/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext.fawe/v1_20_R3/PaperweightServerLevelDelegateProxy.java index 8b52f207e..84727c8c5 100644 --- a/worldedit-bukkit/adapters/adapter-1_20_4/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext.fawe/v1_20_R3/PaperweightServerLevelDelegateProxy.java +++ b/worldedit-bukkit/adapters/adapter-1_20_4/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext.fawe/v1_20_R3/PaperweightServerLevelDelegateProxy.java @@ -104,7 +104,7 @@ public class PaperweightServerLevelDelegateProxy implements InvocationHandler { return null; } BlockEntity newEntity = tileEntity.getType().create(blockPos, getBlockState(blockPos)); - newEntity.load((CompoundTag) adapter.fromNativeBinary(this.editSession.getFullBlock( + newEntity.load((CompoundTag) adapter.fromNativeLin(this.editSession.getFullBlock( blockPos.getX(), blockPos.getY(), blockPos.getZ() diff --git a/worldedit-bukkit/adapters/adapter-1_20_5/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext.fawe/v1_20_R4/PaperweightServerLevelDelegateProxy.java b/worldedit-bukkit/adapters/adapter-1_20_5/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext.fawe/v1_20_R4/PaperweightServerLevelDelegateProxy.java index e223bda2b..f2f32edcb 100644 --- a/worldedit-bukkit/adapters/adapter-1_20_5/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext.fawe/v1_20_R4/PaperweightServerLevelDelegateProxy.java +++ b/worldedit-bukkit/adapters/adapter-1_20_5/src/main/java/com/sk89q/worldedit/bukkit/adapter/ext.fawe/v1_20_R4/PaperweightServerLevelDelegateProxy.java @@ -105,7 +105,7 @@ public class PaperweightServerLevelDelegateProxy implements InvocationHandler { } BlockEntity newEntity = tileEntity.getType().create(blockPos, getBlockState(blockPos)); newEntity.loadWithComponents( - (CompoundTag) adapter.fromNativeBinary(this.editSession.getFullBlock( + (CompoundTag) adapter.fromNativeLin(this.editSession.getFullBlock( blockPos.getX(), blockPos.getY(), blockPos.getZ() diff --git a/worldedit-core/src/main/java/com/fastasyncworldedit/core/extent/processor/PlacementStateProcessor.java b/worldedit-core/src/main/java/com/fastasyncworldedit/core/extent/processor/PlacementStateProcessor.java index 750a9d862..694a11a5e 100644 --- a/worldedit-core/src/main/java/com/fastasyncworldedit/core/extent/processor/PlacementStateProcessor.java +++ b/worldedit-core/src/main/java/com/fastasyncworldedit/core/extent/processor/PlacementStateProcessor.java @@ -24,13 +24,13 @@ import com.sk89q.worldedit.math.Vector3; import com.sk89q.worldedit.regions.Region; import com.sk89q.worldedit.registry.state.Property; import com.sk89q.worldedit.util.Direction; -import com.sk89q.worldedit.util.nbt.CompoundBinaryTag; import com.sk89q.worldedit.world.block.BaseBlock; import com.sk89q.worldedit.world.block.BlockCategories; import com.sk89q.worldedit.world.block.BlockCategory; import com.sk89q.worldedit.world.block.BlockState; import com.sk89q.worldedit.world.block.BlockTypes; import com.sk89q.worldedit.world.block.BlockTypesCache; +import org.enginehub.linbus.tree.LinCompoundTag; import java.util.EnumSet; import java.util.Map; @@ -472,9 +472,9 @@ public abstract class PlacementStateProcessor extends AbstractDelegateExtent imp if (block.getOrdinalChar() != newOrdinal) { BlockState newState = BlockTypesCache.states[newOrdinal]; orDefault.setBlock(set.x(), set.y(), set.z(), newState); - CompoundBinaryTag nbt = block.getNbt(); + CompoundTag nbt = block.getNbtData(); if (nbt != null && newState.getBlockType() == block.getBlockType()) { - orDefault.setTile(set.x(), set.y(), set.z(), (CompoundTag) nbt.asBinaryTag()); + orDefault.setTile(set.x(), set.y(), set.z(), nbt); } return true; } @@ -497,7 +497,7 @@ public abstract class PlacementStateProcessor extends AbstractDelegateExtent imp char newOrdinal = getBlockOrdinal(position.x(), position.y(), position.z(), block.toBlockState()); if (block.getOrdinalChar() != newOrdinal) { BlockState state = BlockTypesCache.states[newOrdinal]; - CompoundBinaryTag nbt = block.getNbt(); + LinCompoundTag nbt = block.getNbt(); if (nbt != null && state.getBlockType() == block.getBlockType()) { state.toBaseBlock(nbt); }