setHealth

public abstract void setHealth(double health)

Sets the entity's health from 0 to getMaxHealth, where 0 is dead.

Parameters

health

New health represented from 0 to max

Throws

Thrown if the health is < 0 or >getMaxHealth