mirror of
https://github.com/PaperMC/Paper.git
synced 2025-03-19 13:38:44 +01:00
SPIGOT-2911: Implement AbstractHorseInventory
By: md_5 <git@md-5.net>
This commit is contained in:
parent
64ceb83927
commit
7071ea8e4e
4 changed files with 29 additions and 16 deletions
|
@ -1,5 +1,6 @@
|
||||||
package org.bukkit.entity;
|
package org.bukkit.entity;
|
||||||
|
|
||||||
|
import org.bukkit.inventory.AbstractHorseInventory;
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -96,4 +97,7 @@ public interface AbstractHorse extends Animals, Vehicle, InventoryHolder, Tameab
|
||||||
* @param strength jump strength for this horse
|
* @param strength jump strength for this horse
|
||||||
*/
|
*/
|
||||||
public void setJumpStrength(double strength);
|
public void setJumpStrength(double strength);
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public AbstractHorseInventory getInventory();
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,23 @@
|
||||||
|
package org.bukkit.inventory;
|
||||||
|
|
||||||
|
import org.bukkit.entity.AbstractHorse;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* An interface to the inventory of an {@link AbstractHorse}.
|
||||||
|
*/
|
||||||
|
public interface AbstractHorseInventory extends Inventory {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the item in the horse's saddle slot.
|
||||||
|
*
|
||||||
|
* @return the saddle item
|
||||||
|
*/
|
||||||
|
ItemStack getSaddle();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the item in the horse's saddle slot.
|
||||||
|
*
|
||||||
|
* @param stack the new item
|
||||||
|
*/
|
||||||
|
void setSaddle(ItemStack stack);
|
||||||
|
}
|
|
@ -3,14 +3,7 @@ package org.bukkit.inventory;
|
||||||
/**
|
/**
|
||||||
* An interface to the inventory of a Horse.
|
* An interface to the inventory of a Horse.
|
||||||
*/
|
*/
|
||||||
public interface HorseInventory extends Inventory {
|
public interface HorseInventory extends AbstractHorseInventory {
|
||||||
|
|
||||||
/**
|
|
||||||
* Gets the item in the horse's saddle slot.
|
|
||||||
*
|
|
||||||
* @return the saddle item
|
|
||||||
*/
|
|
||||||
ItemStack getSaddle();
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the item in the horse's armor slot.
|
* Gets the item in the horse's armor slot.
|
||||||
|
@ -19,13 +12,6 @@ public interface HorseInventory extends Inventory {
|
||||||
*/
|
*/
|
||||||
ItemStack getArmor();
|
ItemStack getArmor();
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets the item in the horse's saddle slot.
|
|
||||||
*
|
|
||||||
* @param stack the new item
|
|
||||||
*/
|
|
||||||
void setSaddle(ItemStack stack);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets the item in the horse's armor slot.
|
* Sets the item in the horse's armor slot.
|
||||||
*
|
*
|
||||||
|
|
|
@ -5,7 +5,7 @@ import org.bukkit.entity.Llama;
|
||||||
/**
|
/**
|
||||||
* An interface to the inventory of a {@link Llama}.
|
* An interface to the inventory of a {@link Llama}.
|
||||||
*/
|
*/
|
||||||
public interface LlamaInventory extends Inventory {
|
public interface LlamaInventory extends AbstractHorseInventory {
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Gets the item in the llama's decor slot.
|
* Gets the item in the llama's decor slot.
|
||||||
|
|
Loading…
Add table
Reference in a new issue