Class TriggerCondition
java.lang.Object
net.playavalon.mythicdungeons.api.parents.DungeonElement
net.playavalon.mythicdungeons.api.parents.TriggerCondition
- All Implemented Interfaces:
Cloneable
,org.bukkit.configuration.serialization.ConfigurationSerializable
,org.bukkit.event.Listener
- Direct Known Subclasses:
ConditionMobWithin
,ConditionMythic
,ConditionPartySize
,ConditionPlayersWithin
,ConditionTimeElapsed
public abstract class TriggerCondition
extends DungeonElement
implements org.bukkit.event.Listener, Cloneable, org.bukkit.configuration.serialization.ConfigurationSerializable
-
Constructor Summary
ConstructorDescriptionTriggerCondition
(String namespace) TriggerCondition
(String namespace, Map<String, Object> config) -
Method Summary
Modifier and TypeMethodDescriptionabstract void
Used to build a hotbar menu for this condition.abstract MenuButton
Creates and returns a button for use with the condition browser menu.abstract boolean
check
(TriggerFireEvent event) CODE RELATING TO EXECUTIONclone()
final void
disable()
final void
enable
(DungeonTrigger trigger) final void
init()
void
Override me if you have additional code to run when this function is DISABLED.void
onEnable()
Override me if you have additional code to run when this function is ENABLED.Methods inherited from class net.playavalon.mythicdungeons.api.parents.DungeonElement
initFields, serialize
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.bukkit.configuration.serialization.ConfigurationSerializable
serialize
-
Constructor Details
-
TriggerCondition
-
TriggerCondition
-
-
Method Details
-
init
public final void init()- Specified by:
init
in classDungeonElement
-
check
CODE RELATING TO EXECUTION -
onEnable
public void onEnable()Override me if you have additional code to run when this function is ENABLED. -
onDisable
public void onDisable()Override me if you have additional code to run when this function is DISABLED. -
enable
-
disable
public final void disable()- Overrides:
disable
in classDungeonElement
-
buildMenuButton
Creates and returns a button for use with the condition browser menu. MenuButton can be initialized with a Spigot Material, and provided with a display name, lore, enchant effect, and amount.- Specified by:
buildMenuButton
in classDungeonElement
- Returns:
- The menu button that will be displayed in the menu.
- See Also:
-
buildHotbarMenu
public abstract void buildHotbarMenu()Used to build a hotbar menu for this condition. Assign `menu` with a new HotbarMenu object and fill out the methods provided.- Specified by:
buildHotbarMenu
in classDungeonElement
- See Also:
-
clone
- Overrides:
clone
in classDungeonElement
-