Conditions

Conditions can be used to alter how your hud will look based on defined circumstances.

Condition Format

conditions:
- %condition key%{%condition arguments%} %match% %action% %action variable%

Condition Key

This is how you will identify which condition you are using.

Condition Arguments

Arguments are different for each condition. They are each separated by a semi-colon(;). If your condition does not have any arguments, you can leave the space blank like this {} .

Match

This is what the condition will check to see if the condition is complete or not. This defaults to true.

Action

This is what the result of the condition will affect.

ActionDescriptionVariableExample

Hide

If the condition is resolves to false, the hud will be hidden.

N/A

N/A

Color

If the condition resolves to true, the hud will be recolored.

Color

green #AABBCC

Texture

If the condition resolves to true, the hud will be retextured.

Texture Path

assets/sword/fill_health.png

Example Conditions

This condition will turn the hud asset's to the color green if the user has the "luck" effect.

conditions:
#Hide if the fill layer is empty.
- progress{l=fill;o=>;v=0} true hide
#Color the hud green if the user has the luck effect.
- effect{e=luck} true color green

Last updated