mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-09 19:49:35 +01:00
SPIGOT-2793: Revert Nameable changes
By: md_5 <git@md-5.net>
This commit is contained in:
parent
07f7249cf2
commit
0da3e1a443
10 changed files with 35 additions and 56 deletions
|
@ -1,28 +0,0 @@
|
||||||
package org.bukkit;
|
|
||||||
|
|
||||||
public interface Nameable {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Gets the custom name on a mob or block. If there is no name this method
|
|
||||||
* will return null.
|
|
||||||
* <p>
|
|
||||||
* This value has no effect on players, they will always use their real
|
|
||||||
* name.
|
|
||||||
*
|
|
||||||
* @return name of the mob/block or null
|
|
||||||
*/
|
|
||||||
public String getCustomName();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets a custom name on a mob or block. This name will be used in death
|
|
||||||
* messages and can be sent to the client as a nameplate over the mob.
|
|
||||||
* <p>
|
|
||||||
* Setting the name to null or an empty string will clear it.
|
|
||||||
* <p>
|
|
||||||
* This value has no effect on players, they will always use their real
|
|
||||||
* name.
|
|
||||||
*
|
|
||||||
* @param name the name to set
|
|
||||||
*/
|
|
||||||
public void setCustomName(String name);
|
|
||||||
}
|
|
|
@ -1,7 +1,6 @@
|
||||||
package org.bukkit.block;
|
package org.bukkit.block;
|
||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.entity.LivingEntity;
|
import org.bukkit.entity.LivingEntity;
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
import org.bukkit.potion.PotionEffect;
|
import org.bukkit.potion.PotionEffect;
|
||||||
|
@ -10,7 +9,7 @@ import org.bukkit.potion.PotionEffectType;
|
||||||
/**
|
/**
|
||||||
* Represents a beacon.
|
* Represents a beacon.
|
||||||
*/
|
*/
|
||||||
public interface Beacon extends BlockState, InventoryHolder, Lockable, Nameable {
|
public interface Beacon extends BlockState, InventoryHolder, Lockable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the list of players within the beacon's range of effect.
|
* Returns the list of players within the beacon's range of effect.
|
||||||
|
|
|
@ -1,13 +1,12 @@
|
||||||
package org.bukkit.block;
|
package org.bukkit.block;
|
||||||
|
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.inventory.BrewerInventory;
|
import org.bukkit.inventory.BrewerInventory;
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a brewing stand.
|
* Represents a brewing stand.
|
||||||
*/
|
*/
|
||||||
public interface BrewingStand extends BlockState, InventoryHolder, Lockable, Nameable {
|
public interface BrewingStand extends BlockState, InventoryHolder, Lockable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* How much time is left in the brewing cycle
|
* How much time is left in the brewing cycle
|
||||||
|
|
|
@ -1,13 +1,12 @@
|
||||||
package org.bukkit.block;
|
package org.bukkit.block;
|
||||||
|
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.inventory.Inventory;
|
import org.bukkit.inventory.Inventory;
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a chest.
|
* Represents a chest.
|
||||||
*/
|
*/
|
||||||
public interface Chest extends BlockState, InventoryHolder, Lockable, Nameable {
|
public interface Chest extends BlockState, InventoryHolder, Lockable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the chest's inventory. If this is a double chest, it returns
|
* Returns the chest's inventory. If this is a double chest, it returns
|
||||||
|
|
|
@ -1,13 +1,12 @@
|
||||||
package org.bukkit.block;
|
package org.bukkit.block;
|
||||||
|
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
import org.bukkit.projectiles.BlockProjectileSource;
|
import org.bukkit.projectiles.BlockProjectileSource;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a dispenser.
|
* Represents a dispenser.
|
||||||
*/
|
*/
|
||||||
public interface Dispenser extends BlockState, InventoryHolder, Lockable, Nameable {
|
public interface Dispenser extends BlockState, InventoryHolder, Lockable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the BlockProjectileSource object for this dispenser.
|
* Gets the BlockProjectileSource object for this dispenser.
|
||||||
|
|
|
@ -1,13 +1,11 @@
|
||||||
package org.bukkit.block;
|
package org.bukkit.block;
|
||||||
|
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a dropper.
|
* Represents a dropper.
|
||||||
*/
|
*/
|
||||||
public interface Dropper extends BlockState, InventoryHolder, Lockable, Nameable {
|
public interface Dropper extends BlockState, InventoryHolder, Lockable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Tries to drop a randomly selected item from the Dropper's inventory,
|
* Tries to drop a randomly selected item from the Dropper's inventory,
|
||||||
* following the normal behavior of a Dropper.
|
* following the normal behavior of a Dropper.
|
||||||
|
|
|
@ -1,13 +1,12 @@
|
||||||
package org.bukkit.block;
|
package org.bukkit.block;
|
||||||
|
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.inventory.FurnaceInventory;
|
import org.bukkit.inventory.FurnaceInventory;
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a furnace.
|
* Represents a furnace.
|
||||||
*/
|
*/
|
||||||
public interface Furnace extends BlockState, InventoryHolder, Lockable, Nameable {
|
public interface Furnace extends BlockState, InventoryHolder, Lockable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get burn time.
|
* Get burn time.
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
package org.bukkit.block;
|
package org.bukkit.block;
|
||||||
|
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a hopper.
|
* Represents a hopper.
|
||||||
*/
|
*/
|
||||||
public interface Hopper extends BlockState, InventoryHolder, Lockable, Nameable { }
|
public interface Hopper extends BlockState, InventoryHolder, Lockable {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
|
@ -1,18 +1,8 @@
|
||||||
package org.bukkit.block;
|
package org.bukkit.block;
|
||||||
|
|
||||||
import org.bukkit.DyeColor;
|
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.inventory.InventoryHolder;
|
import org.bukkit.inventory.InventoryHolder;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents a ShulkerBox.
|
* Represents a ShulkerBox.
|
||||||
*/
|
*/
|
||||||
public interface ShulkerBox extends BlockState, InventoryHolder, Lockable, Nameable {
|
public interface ShulkerBox extends BlockState, InventoryHolder, Lockable { }
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the {@link DyeColor} corresponding to this ShulkerBox
|
|
||||||
*
|
|
||||||
* @return the {@link DyeColor} of this ShulkerBox
|
|
||||||
*/
|
|
||||||
public DyeColor getColor();
|
|
||||||
}
|
|
||||||
|
|
|
@ -2,7 +2,6 @@ package org.bukkit.entity;
|
||||||
|
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.EntityEffect;
|
import org.bukkit.EntityEffect;
|
||||||
import org.bukkit.Nameable;
|
|
||||||
import org.bukkit.Server;
|
import org.bukkit.Server;
|
||||||
import org.bukkit.World;
|
import org.bukkit.World;
|
||||||
import org.bukkit.event.entity.EntityDamageEvent;
|
import org.bukkit.event.entity.EntityDamageEvent;
|
||||||
|
@ -18,7 +17,7 @@ import org.bukkit.event.player.PlayerTeleportEvent.TeleportCause;
|
||||||
/**
|
/**
|
||||||
* Represents a base entity in the world
|
* Represents a base entity in the world
|
||||||
*/
|
*/
|
||||||
public interface Entity extends Metadatable, CommandSender, Nameable {
|
public interface Entity extends Metadatable, CommandSender {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the entity's current position
|
* Gets the entity's current position
|
||||||
|
@ -300,6 +299,30 @@ public interface Entity extends Metadatable, CommandSender, Nameable {
|
||||||
*/
|
*/
|
||||||
public Entity getVehicle();
|
public Entity getVehicle();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets a custom name on a mob. This name will be used in death messages
|
||||||
|
* and can be sent to the client as a nameplate over the mob.
|
||||||
|
* <p>
|
||||||
|
* Setting the name to null or an empty string will clear it.
|
||||||
|
* <p>
|
||||||
|
* This value has no effect on players, they will always use their real
|
||||||
|
* name.
|
||||||
|
*
|
||||||
|
* @param name the name to set
|
||||||
|
*/
|
||||||
|
public void setCustomName(String name);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the custom name on a mob. If there is no name this method will
|
||||||
|
* return null.
|
||||||
|
* <p>
|
||||||
|
* This value has no effect on players, they will always use their real
|
||||||
|
* name.
|
||||||
|
*
|
||||||
|
* @return name of the mob or null
|
||||||
|
*/
|
||||||
|
public String getCustomName();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets whether or not to display the mob's custom name client side. The
|
* Sets whether or not to display the mob's custom name client side. The
|
||||||
* name will be displayed above the mob similarly to a player.
|
* name will be displayed above the mob similarly to a player.
|
||||||
|
|
Loading…
Reference in a new issue