@@ -211,9 +211,9 @@ public class CraftAreaEffectCloud extends CraftEntity implements AreaEffectCloud
|
||||
|
||||
public void setSource(ProjectileSource shooter) {
|
||||
if (shooter instanceof CraftLivingEntity) {
|
||||
getHandle().a((EntityLiving) ((CraftLivingEntity) shooter).getHandle()); // PAIL rename setSource
|
||||
getHandle().setSource((EntityLiving) ((CraftLivingEntity) shooter).getHandle());
|
||||
} else {
|
||||
getHandle().a((EntityLiving) null);
|
||||
getHandle().setSource((EntityLiving) null);
|
||||
}
|
||||
getHandle().projectileSource = shooter;
|
||||
}
|
||||
|
||||
@@ -14,12 +14,12 @@ public class CraftBoat extends CraftVehicle implements Boat {
|
||||
|
||||
@Override
|
||||
public TreeSpecies getWoodType() {
|
||||
return getTreeSpecies(getHandle().r()); // PAIL: Rename getType
|
||||
return getTreeSpecies(getHandle().getType());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setWoodType(TreeSpecies species) {
|
||||
getHandle().a(getBoatType(species)); // PAIL: Rename setType
|
||||
getHandle().setType(getBoatType(species));
|
||||
}
|
||||
|
||||
public double getMaxSpeed() {
|
||||
|
||||
@@ -14,28 +14,28 @@ public class CraftEnderCrystal extends CraftEntity implements EnderCrystal {
|
||||
|
||||
@Override
|
||||
public boolean isShowingBottom() {
|
||||
return getHandle().k(); // PAIL: Rename isShowingBottom
|
||||
return getHandle().isShowingBottom();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setShowingBottom(boolean showing) {
|
||||
getHandle().a(showing); // PAIL: Rename setShowingBottom
|
||||
getHandle().setShowingBottom(showing);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Location getBeamTarget() {
|
||||
BlockPosition pos = getHandle().j(); // PAIL: Rename getBeamTarget
|
||||
BlockPosition pos = getHandle().getBeamTarget();
|
||||
return pos == null ? null : new Location(getWorld(), pos.getX(), pos.getY(), pos.getZ());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setBeamTarget(Location location) {
|
||||
if (location == null) {
|
||||
getHandle().a((BlockPosition) null); // PAIL: Rename setBeamTarget
|
||||
getHandle().setBeamTarget((BlockPosition) null);
|
||||
} else if (location.getWorld() != getWorld()) {
|
||||
throw new IllegalArgumentException("Cannot set beam target location to different world");
|
||||
} else {
|
||||
getHandle().a(new BlockPosition(location.getBlockX(), location.getBlockY(), location.getBlockZ()));
|
||||
getHandle().setBeamTarget(new BlockPosition(location.getBlockX(), location.getBlockY(), location.getBlockZ()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -45,12 +45,12 @@ public class CraftEnderDragon extends CraftComplexLivingEntity implements EnderD
|
||||
|
||||
@Override
|
||||
public Phase getPhase() {
|
||||
return Phase.values()[getHandle().getDataWatcher().get(EntityEnderDragon.a)]; // PAIL: Rename PHASE
|
||||
return Phase.values()[getHandle().getDataWatcher().get(EntityEnderDragon.PHASE)];
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setPhase(Phase phase) {
|
||||
getHandle().cT().a(getMinecraftPhase(phase)); // PAIL: Rename getDragonControllerManager setPhase
|
||||
getHandle().getDragonControllerManager().setControllerPhase(getMinecraftPhase(phase));
|
||||
}
|
||||
|
||||
public static Phase getBukkitPhase(DragonControllerPhase phase) {
|
||||
@@ -58,6 +58,6 @@ public class CraftEnderDragon extends CraftComplexLivingEntity implements EnderD
|
||||
}
|
||||
|
||||
public static DragonControllerPhase getMinecraftPhase(Phase phase) {
|
||||
return DragonControllerPhase.a(phase.ordinal()); // PAIL: Rename getById
|
||||
return DragonControllerPhase.getById(phase.ordinal());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -138,7 +138,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
|
||||
if (entity instanceof EntityEgg) { return new CraftEgg(server, (EntityEgg) entity); }
|
||||
else if (entity instanceof EntitySnowball) { return new CraftSnowball(server, (EntitySnowball) entity); }
|
||||
else if (entity instanceof EntityPotion) {
|
||||
if (!((EntityPotion) entity).n()) { return new CraftSplashPotion(server, (EntityPotion) entity); }
|
||||
if (!((EntityPotion) entity).isLingering()) { return new CraftSplashPotion(server, (EntityPotion) entity); }
|
||||
else { return new CraftLingeringPotion(server, (EntityPotion) entity); }
|
||||
}
|
||||
else if (entity instanceof EntityEnderPearl) { return new CraftEnderPearl(server, (EntityEnderPearl) entity); }
|
||||
@@ -248,7 +248,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
|
||||
}
|
||||
|
||||
public List<org.bukkit.entity.Entity> getNearbyEntities(double x, double y, double z) {
|
||||
List<Entity> notchEntityList = entity.world.a(entity, entity.getBoundingBox().grow(x, y, z), null);
|
||||
List<Entity> notchEntityList = entity.world.getEntities(entity, entity.getBoundingBox().grow(x, y, z), null);
|
||||
List<org.bukkit.entity.Entity> bukkitEntityList = new java.util.ArrayList<org.bukkit.entity.Entity>(notchEntityList.size());
|
||||
|
||||
for (Entity e : notchEntityList) {
|
||||
@@ -555,7 +555,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
|
||||
|
||||
@Override
|
||||
public void setInvulnerable(boolean flag) {
|
||||
getHandle().h(flag); // PAIL: rename setInvulnerable
|
||||
getHandle().setInvulnerable(flag);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -62,7 +62,7 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
||||
}
|
||||
|
||||
public MainHand getMainHand() {
|
||||
return getHandle().cr() == EnumMainHand.LEFT ? MainHand.LEFT : MainHand.RIGHT; // PAIL Rename cr()->getMainHand()
|
||||
return getHandle().getMainHand()== EnumMainHand.LEFT ? MainHand.LEFT : MainHand.RIGHT;
|
||||
}
|
||||
|
||||
public ItemStack getItemInHand() {
|
||||
|
||||
@@ -532,13 +532,13 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
|
||||
@Override
|
||||
public void setAI(boolean ai) {
|
||||
if (this.getHandle() instanceof EntityInsentient) {
|
||||
((EntityInsentient) this.getHandle()).m(!ai); // PAIL: rename
|
||||
((EntityInsentient) this.getHandle()).setAI(!ai);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasAI() {
|
||||
return (this.getHandle() instanceof EntityInsentient) ? !((EntityInsentient) this.getHandle()).cR() : false; // PAIL: rename
|
||||
return (this.getHandle() instanceof EntityInsentient) ? !((EntityInsentient) this.getHandle()).hasAI(): false;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -31,11 +31,11 @@ final class CraftMinecartHopper extends CraftMinecart implements HopperMinecart
|
||||
|
||||
@Override
|
||||
public boolean isEnabled() {
|
||||
return ((EntityMinecartHopper) getHandle()).C(); // PAIL: Rename isEnabled
|
||||
return ((EntityMinecartHopper) getHandle()).isEnabled();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setEnabled(boolean enabled) {
|
||||
((EntityMinecartHopper) getHandle()).k(enabled); // PAIL: Rename setEnabled
|
||||
((EntityMinecartHopper) getHandle()).setEnabled(enabled);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -362,8 +362,11 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
}
|
||||
|
||||
IChatBaseComponent[] components = CraftSign.sanitizeLines(lines);
|
||||
TileEntitySign sign = new TileEntitySign();
|
||||
sign.a(new BlockPosition(loc.getBlockX(), loc.getBlockY(), loc.getBlockZ())); // PAIL: rename
|
||||
System.arraycopy(components, 0, sign.lines, 0, sign.lines.length);
|
||||
|
||||
getHandle().playerConnection.sendPacket(new PacketPlayOutUpdateSign(getHandle().world, new BlockPosition(loc.getBlockX(), loc.getBlockY(), loc.getBlockZ()), components));
|
||||
getHandle().playerConnection.sendPacket(sign.getUpdatePacket());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -28,11 +28,11 @@ public class CraftSpectralArrow extends CraftArrow implements SpectralArrow {
|
||||
|
||||
@Override
|
||||
public int getGlowingTicks() {
|
||||
return getHandle().f; // PAIL: Rename glowingDuration
|
||||
return getHandle().duration;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setGlowingTicks(int duration) {
|
||||
getHandle().f = duration;
|
||||
getHandle().duration = duration;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -93,7 +93,7 @@ public class CraftVillager extends CraftAgeable implements Villager, InventoryHo
|
||||
|
||||
@Override
|
||||
public HumanEntity getTrader() {
|
||||
EntityHuman eh = getHandle().t_(); // PAIL: rename t_ -> getTrader
|
||||
EntityHuman eh = getHandle().getTrader();
|
||||
return eh == null ? null : eh.getBukkitEntity();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user