mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-22 17:27:38 +00:00
Some changes to make the diff between 1.14-snapshot and commanding branch smaller.
This commit is contained in:
parent
0d794c1004
commit
fb91456bdd
@ -89,7 +89,7 @@ public interface IChunk<T extends Future<T>> extends Trimable, Callable<T>, IChu
|
||||
* Filter through all the blocks in the chunk
|
||||
*
|
||||
* @param filter the filter
|
||||
* @param block The filter block
|
||||
* @param block The filter block
|
||||
* @param region The region allowed to filter (may be null)
|
||||
*/
|
||||
void filterBlocks(Filter filter, ChunkFilterBlock block, @Nullable Region region);
|
||||
|
@ -145,7 +145,7 @@ public interface IQueueExtent extends Flushable, Trimable, Extent {
|
||||
* #wrap(IChunk)}
|
||||
*
|
||||
* @param isFull true if a more optimized chunk should be returned
|
||||
* @return
|
||||
* @return a more optimized chunk object
|
||||
*/
|
||||
IChunk create(boolean isFull);
|
||||
|
||||
@ -173,13 +173,16 @@ public interface IQueueExtent extends Flushable, Trimable, Extent {
|
||||
ChunkFilterBlock initFilterBlock();
|
||||
|
||||
/**
|
||||
* Number of chunks in queue
|
||||
* @return
|
||||
* Returns the number of chunks in this queue.
|
||||
*
|
||||
* @return the number of chunks in this queue
|
||||
*/
|
||||
int size();
|
||||
|
||||
/**
|
||||
* @return If queue is empty
|
||||
* Returns <tt>true</tt> if this queue contains no elements.
|
||||
*
|
||||
* @return <tt>true</tt> if this queue contains no elements
|
||||
*/
|
||||
boolean isEmpty();
|
||||
}
|
||||
|
@ -113,8 +113,7 @@ public class CharBlocks implements IBlocks {
|
||||
return get(blocks, layer)[index];
|
||||
}
|
||||
|
||||
public final void set(CharBlocks blocks, int layer, int index,
|
||||
char value) {
|
||||
public final void set(CharBlocks blocks, int layer, int index, char value) {
|
||||
get(blocks, layer)[index] = value;
|
||||
}
|
||||
}
|
||||
|
@ -6,8 +6,6 @@ import com.sk89q.worldedit.world.block.BaseBlock;
|
||||
import com.sk89q.worldedit.world.block.BlockState;
|
||||
import com.sk89q.worldedit.world.block.BlockTypes;
|
||||
|
||||
import java.util.concurrent.Future;
|
||||
|
||||
public abstract class CharGetBlocks extends CharBlocks implements IChunkGet {
|
||||
|
||||
@Override
|
||||
|
@ -1,29 +1,25 @@
|
||||
package com.boydti.fawe.beta.implementation.holder;
|
||||
|
||||
import com.boydti.fawe.beta.IChunk;
|
||||
import com.boydti.fawe.beta.IChunkSet;
|
||||
import com.boydti.fawe.beta.IDelegateChunk;
|
||||
import com.sk89q.jnbt.CompoundTag;
|
||||
|
||||
import java.util.concurrent.Future;
|
||||
|
||||
/**
|
||||
* Implementation of IDelegateChunk
|
||||
*/
|
||||
public class DelegateChunk<U extends IChunk> implements IDelegateChunk<U> {
|
||||
public class DelegateChunk<T extends IChunk> implements IDelegateChunk<T> {
|
||||
|
||||
private U parent;
|
||||
private T parent;
|
||||
|
||||
public DelegateChunk(U parent) {
|
||||
public DelegateChunk(final T parent) {
|
||||
this.parent = parent;
|
||||
}
|
||||
|
||||
@Override
|
||||
public final U getParent() {
|
||||
public final T getParent() {
|
||||
return parent;
|
||||
}
|
||||
|
||||
public final void setParent(U parent) {
|
||||
public final void setParent(final T parent) {
|
||||
this.parent = parent;
|
||||
}
|
||||
}
|
||||
|
@ -25,6 +25,7 @@ import com.boydti.fawe.util.image.ImageViewer;
|
||||
import com.sk89q.jnbt.CompoundTag;
|
||||
import com.sk89q.worldedit.EditSession;
|
||||
import com.sk89q.worldedit.LocalSession;
|
||||
import com.sk89q.worldedit.MaxChangedBlocksException;
|
||||
import com.sk89q.worldedit.WorldEditException;
|
||||
import com.sk89q.worldedit.blocks.BaseItemStack;
|
||||
import com.sk89q.worldedit.entity.Player;
|
||||
@ -43,6 +44,7 @@ import com.sk89q.worldedit.regions.Region;
|
||||
import com.sk89q.worldedit.registry.state.PropertyKey;
|
||||
import com.sk89q.worldedit.session.ClipboardHolder;
|
||||
import com.sk89q.worldedit.util.Location;
|
||||
import com.sk89q.worldedit.util.TreeGenerator;
|
||||
import com.sk89q.worldedit.world.World;
|
||||
import com.sk89q.worldedit.world.biome.BiomeType;
|
||||
import com.sk89q.worldedit.world.biome.BiomeTypes;
|
||||
@ -1946,6 +1948,11 @@ public class HeightMapMCAGenerator extends MCAWriter implements StreamChange, Dr
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean generateTree(TreeGenerator.TreeType type, EditSession editSession, BlockVector3 position) throws MaxChangedBlocksException {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void dropItem(Vector3 position, BaseItemStack item) {
|
||||
// TODO Auto-generated method stub
|
||||
|
@ -31,6 +31,11 @@ public class AbstractDelegateChangeSet extends FaweChangeSet {
|
||||
this.waitingAsync = parent.waitingAsync;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean closeAsync() {
|
||||
return parent.closeAsync();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean flush() {
|
||||
return parent.flush();
|
||||
@ -61,11 +66,6 @@ public class AbstractDelegateChangeSet extends FaweChangeSet {
|
||||
return parent.flushAsync();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean closeAsync() {
|
||||
return parent.closeAsync();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void add(int x, int y, int z, int combinedFrom, int combinedTo) {
|
||||
parent.add(x, y, z, combinedFrom, combinedTo);
|
||||
|
@ -23,6 +23,6 @@ public class CombinedBlockCopy implements RegionFunction {
|
||||
// BlockStateHolder block = source.getBlock(position);
|
||||
BaseBlock block = source.getFullBlock(position);
|
||||
function.apply(position);
|
||||
return destination.setBlock(position.getX(),position.getY(),position.getZ(), block);
|
||||
return destination.setBlock(position, block);
|
||||
}
|
||||
}
|
||||
|
@ -17,6 +17,6 @@ public class SimpleBlockCopy implements RegionFunction {
|
||||
|
||||
@Override
|
||||
public boolean apply(BlockVector3 position) throws WorldEditException {
|
||||
return destination.setBlock(position.getX(),position.getY(),position.getZ(), source.getFullBlock(position));
|
||||
return destination.setBlock(position, source.getFullBlock(position));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user