3
0
Mirror von https://github.com/IntellectualSites/FastAsyncWorldEdit.git synchronisiert 2024-11-08 04:20:06 +01:00

Fix //snow didn't put snow on all types of leaves

For example, //snow didn't work on Oak leaves while it did work as you would expect on Dark Oak leaves. Fixed by adding leaves2 to translucent block list and checking if the block to put snow on is a leaf block when executing //snow.
Dieser Commit ist enthalten in:
SlimSoftware 2017-12-14 21:00:38 +01:00 committet von GitHub
Ursprung 72d0e0d1b2
Commit 099987d439
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 4AEE18F83AFDEB23
2 geänderte Dateien mit 5 neuen und 1 gelöschten Zeilen

Datei anzeigen

@ -1656,8 +1656,11 @@ public class EditSession implements Extent {
// Snow should not cover these blocks // Snow should not cover these blocks
if (BlockType.isTranslucent(id)) { if (BlockType.isTranslucent(id)) {
// Add snow on leaves
if (id != BlockID.LEAVES && id != BlockID.LEAVES) {
break; break;
} }
}
// Too high? // Too high?
if (y == world.getMaxY()) { if (y == world.getMaxY()) {

Datei anzeigen

@ -1346,6 +1346,7 @@ public enum BlockType {
isTranslucent.add(BlockID.BARRIER); isTranslucent.add(BlockID.BARRIER);
isTranslucent.add(BlockID.IRON_TRAP_DOOR); isTranslucent.add(BlockID.IRON_TRAP_DOOR);
isTranslucent.add(BlockID.CARPET); isTranslucent.add(BlockID.CARPET);
isTranslucent.add(BlockID.LEAVES2);
isTranslucent.add(BlockID.STAINED_GLASS_PANE); isTranslucent.add(BlockID.STAINED_GLASS_PANE);
isTranslucent.add(BlockID.DOUBLE_PLANT); isTranslucent.add(BlockID.DOUBLE_PLANT);
isTranslucent.add(BlockID.STANDING_BANNER); isTranslucent.add(BlockID.STANDING_BANNER);