Skip to content

Commit

Permalink
Improve generate tree brush with persistent leaves (IntellectualSites…
Browse files Browse the repository at this point in the history
  • Loading branch information
Aurelien30000 authored Sep 9, 2023
1 parent 2e7d485 commit 63a1d7c
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package com.thevoxelbox.voxelsniper.brush.type;

import com.fastasyncworldedit.core.configuration.Caption;
import com.fastasyncworldedit.core.registry.state.PropertyKey;
import com.sk89q.worldedit.math.BlockVector3;
import com.sk89q.worldedit.world.block.BlockCategories;
import com.sk89q.worldedit.world.block.BlockState;
Expand Down Expand Up @@ -397,7 +398,9 @@ private void generateLeafNodeBlock(int x, int y, int z) {
BlockState block = getBlock(x, y, z);
if (block.isAir()) {
// Creates block.
setBlock(x, clampY(y), z, this.leafType);
setBlockData(x, clampY(y), z, this.leafType
.getDefaultState()
.with(PropertyKey.PERSISTENT, true));
}
}
}
Expand Down

0 comments on commit 63a1d7c

Please sign in to comment.