geforkt von Mirrors/FastAsyncWorldEdit
Revert "start reimplementing entities"
This reverts commit aac02ceea1
.
Dieser Commit ist enthalten in:
Ursprung
6fc68da2ce
Commit
9fc2387f11
@ -89,7 +89,7 @@ public class BukkitEntity implements Entity {
|
||||
|
||||
@Override
|
||||
public com.sk89q.worldedit.world.entity.EntityType getType() {
|
||||
return EntityTypes.get(type.getName().toLowerCase(Locale.ROOT));
|
||||
return EntityTypes.get(type.getName().toUpperCase(Locale.ROOT));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -99,6 +99,7 @@ public class BukkitWorld extends AbstractWorld {
|
||||
@Override
|
||||
public List<com.sk89q.worldedit.entity.Entity> getEntities(Region region) {
|
||||
World world = getWorld();
|
||||
|
||||
List<Entity> ents = world.getEntities();
|
||||
List<com.sk89q.worldedit.entity.Entity> entities = new ArrayList<>();
|
||||
for (Entity ent : ents) {
|
||||
|
@ -63,9 +63,4 @@ public class WorldCopyClipboard extends ReadOnlyClipboard {
|
||||
return hasBiomes;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<? extends Entity> getEntities(Region region) {
|
||||
return getExtent().getEntities(region);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -46,8 +46,6 @@ import com.boydti.fawe.util.ExtentTraverser;
|
||||
import com.boydti.fawe.util.MaskTraverser;
|
||||
import com.boydti.fawe.util.MathMan;
|
||||
import com.boydti.fawe.util.TaskManager;
|
||||
import com.sk89q.worldedit.entity.BaseEntity;
|
||||
import com.sk89q.worldedit.entity.Entity;
|
||||
import com.sk89q.worldedit.entity.Player;
|
||||
import com.sk89q.worldedit.event.extent.EditSessionEvent;
|
||||
import com.sk89q.worldedit.extent.AbstractDelegateExtent;
|
||||
@ -3056,20 +3054,4 @@ public class EditSession extends PassthroughExtent implements AutoCloseable {
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<? extends Entity> getEntities(Region region) {
|
||||
return world.getEntities(region);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<? extends Entity> getEntities() {
|
||||
System.out.println("editsession");
|
||||
return world.getEntities();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Entity createEntity(Location location, BaseEntity entity) {
|
||||
return world.createEntity(location, entity);
|
||||
}
|
||||
}
|
||||
|
@ -132,7 +132,6 @@ public interface Extent extends InputExtent, OutputExtent {
|
||||
* @return a list of entities
|
||||
*/
|
||||
default List<? extends Entity> getEntities() {
|
||||
System.out.println("el");
|
||||
return Collections.emptyList();
|
||||
}
|
||||
|
||||
|
@ -195,19 +195,11 @@ public class BlockArrayClipboard implements Clipboard {
|
||||
|
||||
@Override
|
||||
public List<? extends Entity> getEntities(Region region) {
|
||||
System.out.println("blockarrayclipboard");
|
||||
region = region.clone();
|
||||
region.shift(BlockVector3.ZERO.subtract(origin));
|
||||
return getParent().getEntities(region);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<? extends Entity> getEntities() {
|
||||
System.out.println("blockarrayall");
|
||||
return getParent().getEntities();
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public Entity createEntity(Location location, BaseEntity entity) {
|
||||
|
@ -397,7 +397,7 @@ public class ForwardExtentCopy implements Operation {
|
||||
Operations.completeBlindly(blockCopy);
|
||||
|
||||
if (!entities.isEmpty()) {
|
||||
ExtentEntityCopy entityCopy = new ExtentEntityCopy(from.toVector3(), finalDest, to.toVector3(), currentTransform);
|
||||
ExtentEntityCopy entityCopy = new ExtentEntityCopy(from.toVector3(), destination, to.toVector3(), currentTransform);
|
||||
entityCopy.setRemoving(removingEntities);
|
||||
List<? extends Entity> entities2 = Lists.newArrayList(source.getEntities(region));
|
||||
entities2.removeIf(entity -> {
|
||||
@ -406,7 +406,6 @@ public class ForwardExtentCopy implements Operation {
|
||||
});
|
||||
EntityVisitor entityVisitor = new EntityVisitor(entities.iterator(), entityCopy);
|
||||
Operations.completeBlindly(entityVisitor);
|
||||
affectedEntities += entityVisitor.getAffected();
|
||||
}
|
||||
|
||||
if (transExt != null) {
|
||||
@ -428,8 +427,8 @@ public class ForwardExtentCopy implements Operation {
|
||||
return ImmutableList.of(
|
||||
TranslatableComponent.of("worldedit.operation.affected.block",
|
||||
TextComponent.of(affectedBlocks)).color(TextColor.LIGHT_PURPLE),
|
||||
//TranslatableComponent.of("worldedit.operation.affected.biome",
|
||||
// TextComponent.of(affectedBiomeCols)).color(TextColor.LIGHT_PURPLE),
|
||||
TranslatableComponent.of("worldedit.operation.affected.biome",
|
||||
TextComponent.of(affectedBiomeCols)).color(TextColor.LIGHT_PURPLE),
|
||||
TranslatableComponent.of("worldedit.operation.affected.entity",
|
||||
TextComponent.of(affectedEntities)).color(TextColor.LIGHT_PURPLE)
|
||||
);
|
||||
|
@ -192,7 +192,6 @@ public class NullWorld extends AbstractWorld {
|
||||
|
||||
@Override
|
||||
public List<Entity> getEntities(Region region) {
|
||||
System.out.println("nullworld");
|
||||
return Collections.emptyList();
|
||||
}
|
||||
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren