mirror of
https://github.com/PaperMC/Paper.git
synced 2025-07-31 12:12:08 -07:00
Additional ExplosiveMinecart API (#8896)
This commit is contained in:
@@ -20,6 +20,7 @@ public net.minecraft.world.entity.ambient.Bat targetPosition
|
||||
public net.minecraft.world.entity.monster.Ravager attackTick
|
||||
public net.minecraft.world.entity.monster.Ravager stunnedTick
|
||||
public net.minecraft.world.entity.monster.Ravager roarTick
|
||||
public net.minecraft.world.entity.vehicle.MinecartTNT explode(D)V
|
||||
public net.minecraft.world.entity.vehicle.MinecartTNT fuse
|
||||
public net.minecraft.world.entity.monster.Endermite life
|
||||
public net.minecraft.world.entity.vehicle.MinecartHopper cooldownTime
|
||||
@@ -33,6 +34,7 @@ public net.minecraft.world.entity.animal.Rabbit moreCarrotTicks
|
||||
Co-authored-by: Nassim Jahnke <nassim@njahnke.dev>
|
||||
Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
|
||||
Co-authored-by: William Blake Galbreath <blake.galbreath@gmail.com>
|
||||
Co-authored-by: SoSeDiK <mrsosedik@gmail.com>
|
||||
|
||||
diff --git a/src/main/java/com/destroystokyo/paper/entity/ai/MobGoalHelper.java b/src/main/java/com/destroystokyo/paper/entity/ai/MobGoalHelper.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
@@ -818,6 +820,27 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
+ public int getFuseTicks() {
|
||||
+ return this.getHandle().getFuse();
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public boolean isIgnited() {
|
||||
+ return this.getHandle().isPrimed();
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public void ignite() {
|
||||
+ this.getHandle().primeFuse();
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public void explode() {
|
||||
+ explode(this.getHandle().getDeltaMovement().horizontalDistanceSqr());
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public void explode(double power) {
|
||||
+ com.google.common.base.Preconditions.checkArgument(power >= 0 && Double.isFinite(power), "Explosion power must be a finite non-negative number");
|
||||
+ this.getHandle().explode(power);
|
||||
+ }
|
||||
+ // Paper end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftMushroomCow.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftMushroomCow.java
|
||||
|
Reference in New Issue
Block a user