Gui Button
Represents a clickable button within a GUI, which can have various actions, animations, and metadata.
This class provides the ability to configure a button with an item, assign click actions, manage cooldowns, set up animations, and store additional metadata.
Parameters
The item that represents the button in the inventory.
The action that will be triggered when the button is clicked.
The event scope that controls the conditions under which the button's action is triggered.
The metadata associated with the button.
The delay (in ticks) before the button's action is triggered.
The debounce time (in ticks) to prevent multiple clicks in quick succession.
The throttle time (in milliseconds) to limit how frequently the button's action can be triggered.
A list of item frames for animating the button.
The interval (in ticks) between animation frames.
Constructors
Properties
Functions
Pauses the animation, stopping the frame updates.
Removes the metadata associated with the specified key.
Resumes the animation if it was paused.
Starts the animation for this button, cycling through the provided animation frames.
Stops the animation for this button, resetting the frame index.