geforkt von Mirrors/Paper
SPIGOT-5121: Method to set PierceLevel of arrows
Dieser Commit ist enthalten in:
Ursprung
7a0f61a6e7
Commit
a0e47473ce
@ -39,6 +39,18 @@ public class CraftArrow extends AbstractProjectile implements AbstractArrow {
|
||||
getHandle().setDamage(damage);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getPierceLevel() {
|
||||
return getHandle().s(); // PAIL: rename
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setPierceLevel(int pierceLevel) {
|
||||
Preconditions.checkArgument(0 <= pierceLevel && pierceLevel <= Byte.MAX_VALUE, "Pierce level out of range, expected 0 < level < 127");
|
||||
|
||||
getHandle().b((byte) pierceLevel); // PAIL: rename
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isCritical() {
|
||||
return getHandle().isCritical();
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren