mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-03 23:07:40 +01:00
parent
e43f607e6a
commit
1128edadb2
@ -18,7 +18,7 @@
|
||||
public int maxSwell = 30;
|
||||
public int explosionRadius = 3;
|
||||
private int droppedSkulls;
|
||||
+ private EntityHuman entityIgniter; // CraftBukkit
|
||||
+ public Entity entityIgniter; // CraftBukkit
|
||||
|
||||
public EntityCreeper(EntityTypes<? extends EntityCreeper> entitytypes, World world) {
|
||||
super(entitytypes, world);
|
||||
|
@ -4,6 +4,7 @@ import com.google.common.base.Preconditions;
|
||||
import net.minecraft.world.entity.monster.EntityCreeper;
|
||||
import org.bukkit.craftbukkit.CraftServer;
|
||||
import org.bukkit.entity.Creeper;
|
||||
import org.bukkit.entity.Entity;
|
||||
import org.bukkit.event.entity.CreeperPowerEvent;
|
||||
|
||||
public class CraftCreeper extends CraftMonster implements Creeper {
|
||||
@ -75,11 +76,23 @@ public class CraftCreeper extends CraftMonster implements Creeper {
|
||||
getHandle().explodeCreeper();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void ignite(Entity entity) {
|
||||
Preconditions.checkNotNull(entity, "entity cannot be null");
|
||||
getHandle().entityIgniter = ((CraftEntity) entity).getHandle();
|
||||
getHandle().ignite();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void ignite() {
|
||||
getHandle().ignite();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Entity getIgniter() {
|
||||
return (getHandle().entityIgniter != null) ? getHandle().entityIgniter.getBukkitEntity() : null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityCreeper getHandle() {
|
||||
return (EntityCreeper) entity;
|
||||
|
Loading…
Reference in New Issue
Block a user