Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-18 12:30:06 +01:00
SPIGOT-5061: Add explode and ignite methods to Creeper
Dieser Commit ist enthalten in:
Ursprung
f2757f95b3
Commit
8003ced585
@ -32,7 +32,13 @@
|
||||
@Override
|
||||
protected boolean a(EntityHuman entityhuman, EnumHand enumhand) {
|
||||
ItemStack itemstack = entityhuman.b(enumhand);
|
||||
@@ -192,10 +206,18 @@
|
||||
@@ -187,15 +201,23 @@
|
||||
return super.a(entityhuman, enumhand);
|
||||
}
|
||||
|
||||
- private void eb() {
|
||||
+ public void eb() { // PAIL rename explode, private -> public
|
||||
if (!this.world.isClientSide) {
|
||||
Explosion.Effect explosion_effect = this.world.getGameRules().getBoolean("mobGriefing") ? Explosion.Effect.DESTROY : Explosion.Effect.NONE;
|
||||
float f = this.isPowered() ? 2.0F : 1.0F;
|
||||
|
||||
|
@ -64,6 +64,16 @@ public class CraftCreeper extends CraftMonster implements Creeper {
|
||||
return getHandle().explosionRadius;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void explode() {
|
||||
getHandle().eb();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void ignite() {
|
||||
getHandle().dY(); // PAIL rename ignite
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityCreeper getHandle() {
|
||||
return (EntityCreeper) entity;
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren