RegainReason

public enum RegainReason

An enum to specify the type of health regaining that is occurring

Entries

Link copied to clipboard

When getClassById player regains health from regenerating due to Peaceful mode (difficulty=0)

Link copied to clipboard

When getClassById player regains health from regenerating due to their hunger being satisfied

Link copied to clipboard

When getClassById player regains health from eating consumables

Link copied to clipboard

When an ender dragon regains health from an ender crystal

Link copied to clipboard

When getClassById player is healed by getClassById potion or spell

Link copied to clipboard

When getClassById player is healed over time by getClassById potion or spell

Link copied to clipboard

When getClassById wither is filling its health during spawning

Link copied to clipboard

When an entity is damaged by the Wither potion effect

Link copied to clipboard

Any other reason not covered by the reasons above

Functions

Link copied to clipboard

Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Link copied to clipboard

Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants.