geforkt von Mirrors/FastAsyncWorldEdit
Minor formatting and neatness changes.
Dieser Commit ist enthalten in:
Ursprung
69ab1781c6
Commit
58a5d9961b
@ -62,7 +62,14 @@ public class BukkitBlockRegistry extends BundledBlockRegistry {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isAir() {
|
public boolean isAir() {
|
||||||
return material == Material.AIR || material == Material.CAVE_AIR || material == Material.VOID_AIR;
|
switch (material) {
|
||||||
|
case AIR:
|
||||||
|
case CAVE_AIR:
|
||||||
|
case VOID_AIR:
|
||||||
|
return true;
|
||||||
|
default:
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -22,9 +22,9 @@ package com.sk89q.worldedit.bukkit;
|
|||||||
import static com.google.common.base.Preconditions.checkNotNull;
|
import static com.google.common.base.Preconditions.checkNotNull;
|
||||||
|
|
||||||
import com.sk89q.worldedit.entity.metadata.EntityProperties;
|
import com.sk89q.worldedit.entity.metadata.EntityProperties;
|
||||||
import com.sk89q.worldedit.util.Enums;
|
|
||||||
import org.bukkit.entity.Ambient;
|
import org.bukkit.entity.Ambient;
|
||||||
import org.bukkit.entity.Animals;
|
import org.bukkit.entity.Animals;
|
||||||
|
import org.bukkit.entity.ArmorStand;
|
||||||
import org.bukkit.entity.Boat;
|
import org.bukkit.entity.Boat;
|
||||||
import org.bukkit.entity.ComplexEntityPart;
|
import org.bukkit.entity.ComplexEntityPart;
|
||||||
import org.bukkit.entity.Entity;
|
import org.bukkit.entity.Entity;
|
||||||
@ -46,9 +46,6 @@ import org.bukkit.entity.minecart.ExplosiveMinecart;
|
|||||||
|
|
||||||
class BukkitEntityProperties implements EntityProperties {
|
class BukkitEntityProperties implements EntityProperties {
|
||||||
|
|
||||||
private static final org.bukkit.entity.EntityType armorStandType =
|
|
||||||
Enums.findByValue(org.bukkit.entity.EntityType.class, "ARMOR_STAND");
|
|
||||||
|
|
||||||
private final Entity entity;
|
private final Entity entity;
|
||||||
|
|
||||||
BukkitEntityProperties(Entity entity) {
|
BukkitEntityProperties(Entity entity) {
|
||||||
@ -143,7 +140,7 @@ class BukkitEntityProperties implements EntityProperties {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isArmorStand() {
|
public boolean isArmorStand() {
|
||||||
return entity.getType() == armorStandType;
|
return entity instanceof ArmorStand;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -26,7 +26,6 @@ import com.sk89q.worldedit.extent.inventory.OutOfBlocksException;
|
|||||||
import com.sk89q.worldedit.extent.inventory.OutOfSpaceException;
|
import com.sk89q.worldedit.extent.inventory.OutOfSpaceException;
|
||||||
import com.sk89q.worldedit.util.Location;
|
import com.sk89q.worldedit.util.Location;
|
||||||
import com.sk89q.worldedit.world.block.BlockState;
|
import com.sk89q.worldedit.world.block.BlockState;
|
||||||
import com.sk89q.worldedit.world.block.BlockTypes;
|
|
||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren