public interface IForgeEffect
Modifier and Type | Method and Description |
---|---|
default java.util.List<ItemStack> |
getCurativeItems()
Get a fresh list of items that can cure this Potion.
|
default Effect |
getEffect() |
default int |
getGuiSortColor(EffectInstance potionEffect)
Used for determining
PotionEffect sort order in GUIs. |
default void |
renderHUDEffect(EffectInstance effect,
AbstractGui gui,
int x,
int y,
float z,
float alpha)
Called to draw the this Potion onto the player's ingame HUD when it's active.
|
default void |
renderInventoryEffect(EffectInstance effect,
DisplayEffectsScreen<?> gui,
int x,
int y,
float z)
Called to draw the this Potion onto the player's inventory when it's active.
|
default boolean |
shouldRender(EffectInstance effect)
If the Potion effect should be displayed in the players inventory
|
default boolean |
shouldRenderHUD(EffectInstance effect)
If the Potion effect should be displayed in the player's ingame HUD
|
default boolean |
shouldRenderInvText(EffectInstance effect)
If the standard PotionEffect text (name and duration) should be drawn when this potion is active.
|
default Effect getEffect()
default boolean shouldRender(EffectInstance effect)
effect
- the active PotionEffectdefault boolean shouldRenderInvText(EffectInstance effect)
effect
- the active PotionEffectdefault boolean shouldRenderHUD(EffectInstance effect)
effect
- the active PotionEffectdefault void renderInventoryEffect(EffectInstance effect, DisplayEffectsScreen<?> gui, int x, int y, float z)
effect
- the active PotionEffectgui
- the gui instancex
- the x coordinatey
- the y coordinatez
- the z leveldefault void renderHUDEffect(EffectInstance effect, AbstractGui gui, int x, int y, float z, float alpha)
effect
- the active PotionEffectgui
- the gui instancex
- the x coordinatey
- the y coordinatez
- the z levelalpha
- the alpha value, blinks when the potion is about to run outdefault java.util.List<ItemStack> getCurativeItems()
PotionEffect#getCurativeItems
default int getGuiSortColor(EffectInstance potionEffect)
PotionEffect
sort order in GUIs.
Defaults to the PotionEffect
's liquid color.potionEffect
- the PotionEffect
instance containing the potionPotionEffect
s in GUIs