SPIGOT-2060: Method to control whether entities collide

This commit is contained in:
md_5 committed 2016-03-27 20:19:41 +11:00
1 parent 1ea1adc10f
commit cd36f6f257
2 files changed
+43 -23

No files matched your search

@@ -540,4 +540,14 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
public boolean hasAI() {
return (this.getHandle() instanceof EntityInsentient) ? !((EntityInsentient) this.getHandle()).cR() : false; // PAIL: rename
}
@Override
public void setCollidable(boolean collidable) {
getHandle().collides = collidable;
}
@Override
public boolean isCollidable() {
return getHandle().collides;
}
}