diff --git a/src/main/java/com/sk89q/worldedit/LocalWorld.java b/src/main/java/com/sk89q/worldedit/LocalWorld.java index 9c6785644..cdd8fafee 100644 --- a/src/main/java/com/sk89q/worldedit/LocalWorld.java +++ b/src/main/java/com/sk89q/worldedit/LocalWorld.java @@ -312,7 +312,7 @@ public abstract class LocalWorld { * @return */ public boolean isValidBlockType(int type) { - return !((type > 32 && type < 35) || type == 36 || type == 29 || type > 96); + return type >= 0 && type < 96; } /** diff --git a/src/main/java/com/sk89q/worldedit/blocks/BlockID.java b/src/main/java/com/sk89q/worldedit/blocks/BlockID.java index ec2c22424..ff65f2d7a 100644 --- a/src/main/java/com/sk89q/worldedit/blocks/BlockID.java +++ b/src/main/java/com/sk89q/worldedit/blocks/BlockID.java @@ -54,10 +54,14 @@ public final class BlockID { public static final int BED = 26; public static final int POWERED_RAIL = 27; public static final int DETECTOR_RAIL = 28; + public static final int PISTON_STICKY_BASE = 29; public static final int WEB = 30; public static final int LONG_GRASS = 31; public static final int DEAD_BUSH = 32; + public static final int PISTON_BASE = 33; + public static final int PISTON_EXTENSION = 34; public static final int CLOTH = 35; + public static final int PISTON_MOVING_PIECE = 36; public static final int YELLOW_FLOWER = 37; public static final int RED_FLOWER = 38; public static final int BROWN_MUSHROOM = 39; diff --git a/src/main/java/com/sk89q/worldedit/blocks/BlockType.java b/src/main/java/com/sk89q/worldedit/blocks/BlockType.java index 68e5a1737..7ea89827a 100644 --- a/src/main/java/com/sk89q/worldedit/blocks/BlockType.java +++ b/src/main/java/com/sk89q/worldedit/blocks/BlockType.java @@ -60,10 +60,14 @@ public enum BlockType { BED(26, "Bed", "bed"), POWERED_RAIL(27, "Powered Rail", "poweredrail", "boosterrail", "poweredtrack", "boostertrack", "booster"), DETECTOR_RAIL(28, "Detector Rail", "detectorrail", "detector"), + PISTON_STICKY_BASE(29, "Sticky Piston", "stickypiston"), WEB(30, "Web", "web", "spiderweb"), LONG_GRASS(31, "Long grass", "longgrass", "tallgrass"), DEAD_BUSH(32, "Shrub", "deadbush", "shrub", "deadshrub", "tumbleweed"), + PISTON_BASE(33, "Piston", "piston"), + PISTON_EXTENSION(34, "Piston extension", "pistonextendsion", "pistonhead"), CLOTH(35, "Wool", "cloth", "wool"), + PISTON_MOVING_PIECE(36, "Piston moving piece", "movingpiston"), YELLOW_FLOWER(37, "Yellow flower", "yellowflower", "flower"), RED_FLOWER(38, "Red rose", "redflower", "redrose", "rose"), BROWN_MUSHROOM(39, "Brown mushroom", "brownmushroom", "mushroom"), @@ -159,7 +163,9 @@ public enum BlockType { blockDrops.put(27, 27); blockDrops.put(28, 28); blockDrops.put(30, 30); + blockDrops.put(34, -1); blockDrops.put(35, 35); + blockDrops.put(36, -1); blockDrops.put(37, 37); blockDrops.put(38, 38); blockDrops.put(39, 39); diff --git a/src/main/java/com/sk89q/worldedit/blocks/ItemType.java b/src/main/java/com/sk89q/worldedit/blocks/ItemType.java index 8c354ac1f..da9286dca 100644 --- a/src/main/java/com/sk89q/worldedit/blocks/ItemType.java +++ b/src/main/java/com/sk89q/worldedit/blocks/ItemType.java @@ -62,10 +62,14 @@ public enum ItemType { BED(26, "Bed", "bed"), POWERED_RAIL(27, "Powered Rail", "poweredrail", "boosterrail", "poweredtrack", "boostertrack", "booster"), DETECTOR_RAIL(28, "Detector Rail", "detectorrail", "detector"), + PISTON_STICKY_BASE(29, "Sticky Piston", "stickypiston"), WEB(30, "Web", "web", "spiderweb"), LONG_GRASS(31, "Long grass", "longgrass", "tallgrass"), DEAD_BUSH(32, "Shrub", "deadbush", "shrub", "deadshrub", "tumbleweed"), + PISTON_BASE(33, "Piston", "piston"), + PISTON_EXTENSION(34, "Piston extension", "pistonhead"), CLOTH(35, "Wool", "cloth", "wool"), + PISTON_MOVING_PIECE(36, "Piston moving piece", "movingpiston"), YELLOW_FLOWER(37, "Yellow flower", "yellowflower", "flower"), RED_FLOWER(38, "Red rose", "redflower", "redrose", "rose"), BROWN_MUSHROOM(39, "Brown mushroom", "brownmushroom", "mushroom"), @@ -231,6 +235,7 @@ public enum ItemType { REDSTONE_REPEATER(356, "Redstone repeater", "redstonerepeater", "diode", "delayer", "repeater"), COOKIE(357, "Cookie", "cookie"), MAP(358, "Map", "map"), + SHEARS(359, "Shears", "shears", "scissors"), GOLD_RECORD(2256, "Gold Record", "goldrecord", "golddisc"), GREEN_RECORD(2257, "Green Record", "greenrecord", "greenddisc");