Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-22 14:28:09 +01:00
Add API to get / set base arrow damage
Dieser Commit ist enthalten in:
Ursprung
531c25d73f
Commit
63db044596
@ -26,6 +26,17 @@ public class CraftArrow extends AbstractProjectile implements Arrow {
|
||||
return getHandle().knockbackStrength;
|
||||
}
|
||||
|
||||
@Override
|
||||
public double getDamage() {
|
||||
return getHandle().getDamage();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setDamage(double damage) {
|
||||
Preconditions.checkArgument(damage >= 0, "Damage must be positive");
|
||||
getHandle().setDamage(damage);
|
||||
}
|
||||
|
||||
public boolean isCritical() {
|
||||
return getHandle().isCritical();
|
||||
}
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren