mirror of
https://github.com/PaperMC/Paper.git
synced 2024-09-12 15:08:27 +02:00
SPIGOT-4911: Cannot add firework rocket as charged projectile in crossbow
This commit is contained in:
parent
8ad02cd9c7
commit
21dbe8ab2a
@ -141,7 +141,7 @@ public class CraftMetaCrossbow extends CraftMetaItem implements CrossbowMeta {
|
||||
@Override
|
||||
public void addChargedProjectile(ItemStack item) {
|
||||
Preconditions.checkArgument(item != null, "item");
|
||||
Preconditions.checkArgument(CraftMagicNumbers.getItem(item.getType()) instanceof ItemArrow, "Item %s is not an arrow", item);
|
||||
Preconditions.checkArgument(item.getType() == Material.FIREWORK_ROCKET || CraftMagicNumbers.getItem(item.getType()) instanceof ItemArrow, "Item %s is not an arrow or firework rocket", item);
|
||||
|
||||
if (chargedProjectiles == null) {
|
||||
chargedProjectiles = new ArrayList<>();
|
||||
|
Loading…
Reference in New Issue
Block a user