Anvil Gui - on Open/Close/Click Section (Section) — Lusk
Addon: Lusk · Category: Section · Since: 1.3
Syntax
[execute|run] on anvil [gui|inventory] (open|close|click) of %~anvilguiinventory%Description
Runs the code inside of it when the provided anvil gui is opened, closed or clicked.
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
set {_anvilGui} to a new anvil gui
when {_anvilGui} gets opened:
broadcast "%{_anvilGui}% has been opened!"
when {_anvilGui} gets clicked:
broadcast "%{_anvilGui}% has been clicked!"
when {_anvilGui} gets closed:
broadcast "%{_anvilGui}% has been closed!"