Rename setCopyEntities to setCopyingEntities

This commit is contained in:
Jesse Boyd 2018-08-17 18:33:37 +10:00
parent 36ede1b27d
commit 177bfaa930
No known key found for this signature in database
GPG Key ID: 59F1DE6293AF6E1F
5 changed files with 9 additions and 12 deletions

View File

@ -1,6 +1,5 @@
package com.boydti.fawe.object.schematic;
import com.boydti.fawe.config.Settings;
import com.boydti.fawe.object.HasFaweQueue;
import com.boydti.fawe.object.clipboard.FaweClipboard;
import com.boydti.fawe.object.clipboard.ReadOnlyClipboard;
@ -11,7 +10,6 @@ import com.sk89q.worldedit.MaxChangedBlocksException;
import com.sk89q.worldedit.MutableBlockVector2D;
import com.sk89q.worldedit.Vector;
import com.sk89q.worldedit.WorldEditException;
import com.sk89q.worldedit.blocks.BaseBlock;
import com.sk89q.worldedit.world.block.BlockState;
import com.sk89q.worldedit.entity.Entity;
import com.sk89q.worldedit.extent.Extent;
@ -37,7 +35,6 @@ import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStream;
import java.util.function.Consumer;
import javax.annotation.Nullable;
@ -150,7 +147,7 @@ public class Schematic {
if (transform != null && !transform.isIdentity()) {
copy.setTransform(transform);
}
copy.setCopyEntities(copyEntities);
copy.setCopyingEntities(copyEntities);
if (sourceMask != null) {
new MaskTraverser(sourceMask).reset(extent);
copy.setSourceMask(sourceMask);

View File

@ -1832,7 +1832,7 @@ public class EditSession extends AbstractDelegateExtent implements HasFaweQueue,
final Vector size = region.getMaximumPoint().subtract(region.getMinimumPoint()).add(1, 1, 1);
final Vector to = region.getMinimumPoint();
final ForwardExtentCopy copy = new ForwardExtentCopy(EditSession.this, region, EditSession.this, to);
copy.setCopyEntities(copyEntities);
copy.setCopyingEntities(copyEntities);
copy.setCopyBiomes(copyBiomes);
copy.setRepetitions(count);
copy.setTransform(new AffineTransform().translate(dir.multiply(size)));
@ -1890,7 +1890,7 @@ public class EditSession extends AbstractDelegateExtent implements HasFaweQueue,
final BlockReplace remove = replacement instanceof ExistingPattern ? null : new BlockReplace(EditSession.this, replacement);
copy.setCopyBiomes(copyBiomes);
copy.setCopyEntities(copyEntities);
copy.setCopyingEntities(copyEntities);
copy.setSourceFunction(remove);
copy.setRepetitions(1);
Mask sourceMask = getSourceMask();

View File

@ -165,7 +165,7 @@ public class ClipboardCommands extends MethodCommands {
clipboard.setOrigin(session.getPlacementPosition(player));
ForwardExtentCopy copy = new ForwardExtentCopy(editSession, region, clipboard, region.getMinimumPoint());
copy.setCopyEntities(!skipEntities);
copy.setCopyingEntities(!skipEntities);
copy.setCopyBiomes(copyBiomes);
Mask sourceMask = editSession.getSourceMask();
if (sourceMask != null) {
@ -255,7 +255,7 @@ public class ClipboardCommands extends MethodCommands {
clipboard.setOrigin(session.getPlacementPosition(player));
ForwardExtentCopy copy = new ForwardExtentCopy(editSession, region, clipboard, region.getMinimumPoint());
copy.setSourceFunction(new BlockReplace(editSession, leavePattern));
copy.setCopyEntities(!skipEntities);
copy.setCopyingEntities(!skipEntities);
copy.setCopyBiomes(copyBiomes);
Mask sourceMask = editSession.getSourceMask();
if (sourceMask != null) {

View File

@ -149,11 +149,11 @@ public class ForwardExtentCopy implements Operation {
return sourceMask;
}
public void setCopyEntities(boolean copyEntities) {
public void setCopyingEntities(boolean copyEntities) {
this.copyEntities = copyEntities;
}
public boolean isCopyEntities() {
public boolean isCopyingEntities() {
return copyEntities;
}
@ -347,7 +347,7 @@ public class ForwardExtentCopy implements Operation {
blockCopy = new RegionVisitor(region, copy, queue instanceof MappedFaweQueue ? (MappedFaweQueue) queue : null);
}
List<? extends Entity> entities = isCopyEntities() ? source.getEntities(region) : new ArrayList<>();
List<? extends Entity> entities = isCopyingEntities() ? source.getEntities(region) : new ArrayList<>();
for (int i = 0; i < repetitions; i++) {
Operations.completeBlindly(blockCopy);

View File

@ -113,7 +113,7 @@ public class PasteBuilder {
}
ForwardExtentCopy copy = new ForwardExtentCopy(extent, clipboard.getRegion(), clipboard.getOrigin(), targetExtent, to);
copy.setTransform(transform);
copy.setCopyEntities(!ignoreEntities);
copy.setCopyingEntities(!ignoreEntities);
copy.setCopyBiomes((!ignoreBiomes) && (!(clipboard instanceof BlockArrayClipboard) || ((BlockArrayClipboard) clipboard).IMP.hasBiomes()));
if (this.canApply != null) {
copy.setFilterFunction(this.canApply);