You can mimic a low-health pulse by combining a Ticker (to drive a fading variable) with a loading requirement and opacity math.
-
Add a Ticker and give it an action script that updates a variable each tick. For example, use
Set Variable Valuewith something like
pulse_strength:{"placeholder":"calc","values":{"decimal":"true","expression":"(Math.sin(({"placeholder":"world_time"} / 4) * (1 + 1 - {"placeholder":"current_player_health_percent"} / 100)) + 1) * 0.5"}}
This gives you a value between 0 and 1 that pulses faster ascurrent_player_health_percentdrops. (Thecalcplaceholder logic is explained in the Placeholders doc.) -
On your health bar element, add a Loading Requirement — e.g.,
Is Numberchecking thatcurrent_player_health_percentis below whatever low-health threshold you want. That keeps the pulse visible only when you’re hurt. -
Use the variable from step 1 in the element’s Opacity (or tint) field via a placeholder:
{"placeholder":"getvariable","values":{"name":"pulse_strength"}}
The Element Opacity doc covers using placeholders to drive opacity so you can make it fade in/out. -
If you want the entire element to flash rather than just fade, you can also toggle visibility with the same variable (e.g.,
Is Numberrequirement testing whetherpulse_strengthis above 0.5) — you’ll get a faster blink as health drops because the Ticker is scaling frequency withcurrent_player_health_percent.
That setup gives you a heartbeat-style pulse only when health is low, with the pulse speeding up the lower the percent gets.