From 4127e83749426068abebab2112607b3d9ecca7bc Mon Sep 17 00:00:00 2001 From: Aurora Date: Mon, 12 Oct 2020 11:57:39 +0200 Subject: [PATCH] Don't paste ComplexEntityParts --- .../worldedit/function/operation/ForwardExtentCopy.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/worldedit-core/src/main/java/com/sk89q/worldedit/function/operation/ForwardExtentCopy.java b/worldedit-core/src/main/java/com/sk89q/worldedit/function/operation/ForwardExtentCopy.java index 0ac331042..ae7fd5dcc 100644 --- a/worldedit-core/src/main/java/com/sk89q/worldedit/function/operation/ForwardExtentCopy.java +++ b/worldedit-core/src/main/java/com/sk89q/worldedit/function/operation/ForwardExtentCopy.java @@ -382,10 +382,11 @@ public class ForwardExtentCopy implements Operation { List entities; if (copyingEntities) { // filter players since they can't be copied - entities = source.getEntities(region) - .stream() - .filter(e -> e.getType() != EntityTypes.PLAYER) - .collect(Collectors.toList()); + entities = source.getEntities(region); + entities.removeIf(entity -> { + EntityProperties properties = entity.getFacet(EntityProperties.class); + return properties != null && !properties.isPasteable(); + }); } else { entities = Collections.emptyList(); }