diff options
Diffstat (limited to 'src/main')
4 files changed, 3 insertions, 42 deletions
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftAreaEffectCloud.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftAreaEffectCloud.java index 5f068416..577ea29a 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftAreaEffectCloud.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftAreaEffectCloud.java @@ -207,7 +207,7 @@ public class CraftAreaEffectCloud extends CraftEntity implements AreaEffectCloud } public ProjectileSource getSource() { - EntityLiving source = getHandle().y(); // PAIL: rename + EntityLiving source = getHandle().getSource(); return (source == null) ? null : (LivingEntity) source.getBukkitEntity(); } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java index 34dac82f..9ef7686b 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java @@ -686,7 +686,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { @Override public PistonMoveReaction getPistonMoveReaction() { - return PistonMoveReaction.getById(getHandle().o_().ordinal()); // PAIL: rename + return PistonMoveReaction.getById(getHandle().getPushReaction().ordinal()); } protected NBTTagCompound save() { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java index 922a0f0e..e2083fb2 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java @@ -134,32 +134,6 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { return getEyeHeight(); } - private List<Block> getLineOfSight(HashSet<Byte> transparent, int maxDistance, int maxLength) { - if (maxDistance > 120) { - maxDistance = 120; - } - ArrayList<Block> blocks = new ArrayList<Block>(); - Iterator<Block> itr = new BlockIterator(this, maxDistance); - while (itr.hasNext()) { - Block block = itr.next(); - blocks.add(block); - if (maxLength != 0 && blocks.size() > maxLength) { - blocks.remove(0); - } - int id = block.getTypeId(); - if (transparent == null) { - if (id != 0) { - break; - } - } else { - if (!transparent.contains((byte) id)) { - break; - } - } - } - return blocks; - } - private List<Block> getLineOfSight(Set<Material> transparent, int maxDistance, int maxLength) { if (maxDistance > 120) { maxDistance = 120; @@ -186,28 +160,15 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { return blocks; } - public List<Block> getLineOfSight(HashSet<Byte> transparent, int maxDistance) { - return getLineOfSight(transparent, maxDistance, 0); - } - public List<Block> getLineOfSight(Set<Material> transparent, int maxDistance) { return getLineOfSight(transparent, maxDistance, 0); } - public Block getTargetBlock(HashSet<Byte> transparent, int maxDistance) { - List<Block> blocks = getLineOfSight(transparent, maxDistance, 1); - return blocks.get(0); - } - public Block getTargetBlock(Set<Material> transparent, int maxDistance) { List<Block> blocks = getLineOfSight(transparent, maxDistance, 1); return blocks.get(0); } - public List<Block> getLastTwoTargetBlocks(HashSet<Byte> transparent, int maxDistance) { - return getLineOfSight(transparent, maxDistance, 2); - } - public List<Block> getLastTwoTargetBlocks(Set<Material> transparent, int maxDistance) { return getLineOfSight(transparent, maxDistance, 2); } diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBlockState.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBlockState.java index 436e8d04..03d0f5c3 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBlockState.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBlockState.java @@ -245,7 +245,7 @@ public class CraftMetaBlockState extends CraftMetaItem implements BlockStateMeta break; } } - TileEntity te = (blockEntityTag == null) ? null : TileEntity.a(null, blockEntityTag); + TileEntity te = (blockEntityTag == null) ? null : TileEntity.create(null, blockEntityTag); switch (material) { case SIGN: |