mirror of
https://github.com/EngineHub/WorldEdit.git
synced 2024-12-21 04:49:51 +08:00
Added new log/leaves to floating tree remover tool.
This commit is contained in:
parent
40e49f7f74
commit
ca44ee073a
@ -51,7 +51,9 @@ public boolean actPrimary(ServerInterface server, LocalConfiguration config,
|
||||
|
||||
switch (world.getBlockType(clicked)) {
|
||||
case BlockID.LOG:
|
||||
case BlockID.LOG2:
|
||||
case BlockID.LEAVES:
|
||||
case BlockID.LEAVES2:
|
||||
case BlockID.BROWN_MUSHROOM_CAP:
|
||||
case BlockID.RED_MUSHROOM_CAP:
|
||||
case BlockID.VINE:
|
||||
@ -75,7 +77,9 @@ public boolean actPrimary(ServerInterface server, LocalConfiguration config,
|
||||
final int typeId = editSession.getBlock(blockVector).getType();
|
||||
switch (typeId) {
|
||||
case BlockID.LOG:
|
||||
case BlockID.LOG2:
|
||||
case BlockID.LEAVES:
|
||||
case BlockID.LEAVES2:
|
||||
case BlockID.BROWN_MUSHROOM_CAP:
|
||||
case BlockID.RED_MUSHROOM_CAP:
|
||||
case BlockID.VINE:
|
||||
@ -131,7 +135,9 @@ private Set<Vector> bfs(LocalWorld world, Vector origin) throws MaxChangedBlocks
|
||||
continue;
|
||||
|
||||
case BlockID.LOG:
|
||||
case BlockID.LOG2:
|
||||
case BlockID.LEAVES:
|
||||
case BlockID.LEAVES2:
|
||||
case BlockID.BROWN_MUSHROOM_CAP:
|
||||
case BlockID.RED_MUSHROOM_CAP:
|
||||
case BlockID.VINE:
|
||||
@ -142,7 +148,8 @@ private Set<Vector> bfs(LocalWorld world, Vector origin) throws MaxChangedBlocks
|
||||
default:
|
||||
// we hit something solid - evaluate where we came from
|
||||
final int curId = world.getBlockType(current);
|
||||
if (curId == BlockID.LEAVES || curId == BlockID.VINE) {
|
||||
if (curId == BlockID.LEAVES || curId == BlockID.LEAVES2
|
||||
|| curId == BlockID.VINE) {
|
||||
// leaves touching a wall/the ground => stop walking this route
|
||||
continue;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user