Entity - on Heal Section (Section) — Lusk

Addon: Lusk · Category: Section · Since: 1.1

Syntax

[execute|run] on heal of %~entity%

Description

Runs the code inside of it when the provided entity gets healed. Local Variables that are: - defined BEFORE this section CAN be used inside of it. - defined AFTER this section CANNOT be used inside of it. - defined INSIDE this section CANNOT be used outside of it.

Examples

command /a:
  trigger:
    spawn pig at player:
      set display name of entity to "&dPig &7- &c%health of entity%&8/&c%max health of entity%"
      on heal of entity:
        push entity upwards
        broadcast "%entity% has been healed, yay"

View source