geforkt von Mirrors/Paper
SPIGOT-5899: Hoglins API similar to Piglins
By: md_5 <git@md-5.net>
Dieser Commit ist enthalten in:
Ursprung
ee04822ac1
Commit
8c8b0c69df
@ -3,4 +3,61 @@ package org.bukkit.entity;
|
||||
/**
|
||||
* Represents a Hoglin.
|
||||
*/
|
||||
public interface Hoglin extends Animals { }
|
||||
public interface Hoglin extends Animals {
|
||||
|
||||
/**
|
||||
* Gets whether the hoglin is immune to zombification.
|
||||
*
|
||||
* @return Whether the hoglin is immune to zombification
|
||||
*/
|
||||
public boolean isImmuneToZombification();
|
||||
|
||||
/**
|
||||
* Sets whether the hoglin is immune to zombification.
|
||||
*
|
||||
* @param flag Whether the hoglin is immune to zombification
|
||||
*/
|
||||
public void setImmuneToZombification(boolean flag);
|
||||
|
||||
/**
|
||||
* Get whether the hoglin is able to be hunted by piglins.
|
||||
*
|
||||
* @return Whether the hoglin is able to be hunted by piglins
|
||||
*/
|
||||
public boolean isAbleToBeHunted();
|
||||
|
||||
/**
|
||||
* Sets whether the hoglin is able to be hunted by piglins.
|
||||
*
|
||||
* @param flag Whether the hoglin is able to be hunted by piglins.
|
||||
*/
|
||||
public void setIsAbleToBeHunted(boolean flag);
|
||||
|
||||
/**
|
||||
* Gets the amount of ticks until this entity will be converted to a Zoglin.
|
||||
*
|
||||
* When this reaches 300, the entity will be converted.
|
||||
*
|
||||
* @return conversion time
|
||||
* @throws IllegalStateException if {@link #isConverting()} is false.
|
||||
*/
|
||||
public int getConversionTime();
|
||||
|
||||
/**
|
||||
* Sets the amount of ticks until this entity will be converted to a Zoglin.
|
||||
*
|
||||
* When this reaches 0, the entity will be converted. A value of less than 0
|
||||
* will stop the current conversion process without converting the current
|
||||
* entity.
|
||||
*
|
||||
* @param time new conversion time
|
||||
*/
|
||||
public void setConversionTime(int time);
|
||||
|
||||
/**
|
||||
* Get if this entity is in the process of converting to a Zoglin.
|
||||
*
|
||||
* @return conversion status
|
||||
*/
|
||||
boolean isConverting();
|
||||
}
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren