mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-09 11:44:19 +01:00
SPIGOT-2902: Deprecate Damageable methods in favour of Attributes.
By: md_5 <git@md-5.net>
This commit is contained in:
parent
6d7bd7b8d4
commit
1630d4344b
1 changed files with 8 additions and 0 deletions
|
@ -1,5 +1,7 @@
|
||||||
package org.bukkit.entity;
|
package org.bukkit.entity;
|
||||||
|
|
||||||
|
import org.bukkit.attribute.Attribute;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Represents an {@link Entity} that has health and can take damage.
|
* Represents an {@link Entity} that has health and can take damage.
|
||||||
*/
|
*/
|
||||||
|
@ -84,7 +86,9 @@ public interface Damageable extends Entity {
|
||||||
* Gets the maximum health this entity has.
|
* Gets the maximum health this entity has.
|
||||||
*
|
*
|
||||||
* @return Maximum health
|
* @return Maximum health
|
||||||
|
* @deprecated use {@link Attribute#GENERIC_MAX_HEALTH}.
|
||||||
*/
|
*/
|
||||||
|
@Deprecated
|
||||||
double getMaxHealth();
|
double getMaxHealth();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -107,7 +111,9 @@ public interface Damageable extends Entity {
|
||||||
* {@link Wither}, etc...} will have their bar scaled accordingly.
|
* {@link Wither}, etc...} will have their bar scaled accordingly.
|
||||||
*
|
*
|
||||||
* @param health amount of health to set the maximum to
|
* @param health amount of health to set the maximum to
|
||||||
|
* @deprecated use {@link Attribute#GENERIC_MAX_HEALTH}.
|
||||||
*/
|
*/
|
||||||
|
@Deprecated
|
||||||
void setMaxHealth(double health);
|
void setMaxHealth(double health);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -122,6 +128,8 @@ public interface Damageable extends Entity {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Resets the max health to the original amount.
|
* Resets the max health to the original amount.
|
||||||
|
* @deprecated use {@link Attribute#GENERIC_MAX_HEALTH}.
|
||||||
*/
|
*/
|
||||||
|
@Deprecated
|
||||||
void resetMaxHealth();
|
void resetMaxHealth();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue