mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 09:47:38 +00:00
Reverted block id checking in BukkitWorld to prevent false positives and made LoclWorld use the internal list for easier updates
This commit is contained in:
parent
bd52ed5c33
commit
afa8e873e9
@ -23,6 +23,7 @@ import java.util.Random;
|
||||
import com.sk89q.worldedit.blocks.BaseBlock;
|
||||
import com.sk89q.worldedit.blocks.BaseItemStack;
|
||||
import com.sk89q.worldedit.blocks.BlockID;
|
||||
import com.sk89q.worldedit.blocks.BlockType;
|
||||
import com.sk89q.worldedit.blocks.ItemType;
|
||||
import com.sk89q.worldedit.regions.Region;
|
||||
|
||||
@ -434,7 +435,7 @@ public abstract class LocalWorld {
|
||||
* @return
|
||||
*/
|
||||
public boolean isValidBlockType(int type) {
|
||||
return type >= 0 && type < 96;
|
||||
return BlockType.fromID(type) != null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -670,7 +670,7 @@ public class BukkitWorld extends LocalWorld {
|
||||
*/
|
||||
@Override
|
||||
public boolean isValidBlockType(int type) {
|
||||
return type <= 255 && (Material.getMaterial(type) != null || BlockType.fromID(type) != null); // Bukkit isn't always updated before WorldEdit is
|
||||
return type <= 255 && Material.getMaterial(type) != null;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
Reference in New Issue
Block a user