Package me.deecaad.core.mechanics
Class PlayerEffectMechanic
java.lang.Object
me.deecaad.core.mechanics.defaultmechanics.Mechanic
me.deecaad.core.mechanics.PlayerEffectMechanic
- All Implemented Interfaces:
InlineSerializer<Mechanic>,Serializer<Mechanic>,net.kyori.adventure.key.Keyed,org.bukkit.Keyed
- Direct Known Subclasses:
CustomSoundMechanic,FireworkMechanic,SoundMechanic
-
Nested Class Summary
Nested classes/interfaces inherited from interface me.deecaad.core.file.InlineSerializer
InlineSerializer.FormatException -
Field Summary
Fields inherited from class me.deecaad.core.mechanics.defaultmechanics.Mechanic
conditions, targeterFields inherited from interface me.deecaad.core.file.InlineSerializer
NAME_FINDER, UNIQUE_IDENTIFIER -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract @Nullable Targeterabstract voidSimilar toMechanic.use0(CastData)but instead of using this Mechanic's viewer targeter and viewer conditions, the mechanic is used for the given viewer.Methods inherited from class me.deecaad.core.mechanics.defaultmechanics.Mechanic
applyParentArgs, getChance, getConditions, getDelayBeforePlay, getRepeatAmount, getRepeatInterval, getTargeter, handleTargetersAndConditions, use, use0Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface me.deecaad.core.file.InlineSerializer
getInlineKeyword, getKey, getKeyword, shouldSerializeMethods inherited from interface org.bukkit.Keyed
keyMethods inherited from interface me.deecaad.core.file.Serializer
canUsePathTo, getName, getParentKeywords, getWikiLink, letPassThrough, serialize, tryPathTo, useLater
-
Constructor Details
-
PlayerEffectMechanic
public PlayerEffectMechanic()
-
-
Method Details
-
playFor
Similar toMechanic.use0(CastData)but instead of using this Mechanic's viewer targeter and viewer conditions, the mechanic is used for the given viewer.This is done to address a performance issue associated with having multiple per-player mechanics in the same list. See #311 for more info.
- Parameters:
castData- The source of the mechanic... who is casting.viewers- The target of the mechanic.
-
getViewerTargeter
-
getViewerConditions
-