Class BROOM_FLYING
java.lang.Object
net.pottercraft.ollivanders2.effect.O2Effect
net.pottercraft.ollivanders2.effect.FLYING
net.pottercraft.ollivanders2.effect.BROOM_FLYING
Variant of the FLYING effect optimized for broom-based flight with permanent duration and no smoke effects.
BROOM_FLYING is a specialized flight effect that extends the base FLYING effect with modifications
suitable for magical broom flight. Unlike regular FLYING effects, broom flight is always permanent and does not
produce smoke particle effects, resulting in cleaner visual flight for broom-mounted players.
Differences from parent FLYING effect:
- Always permanent - duration parameter is ignored
- Smoke effects disabled (doSmokeEffect = false) for cleaner visuals
- Suitable for persistent broom-based flight mechanics
- See Also:
-
Field Summary
Fields inherited from class net.pottercraft.ollivanders2.effect.O2Effect
affectedPlayerText, duration, effectType, informousText, kill, legilimensText, p, permanent, targetID -
Constructor Summary
ConstructorsConstructorDescriptionBROOM_FLYING(@NotNull Ollivanders2 plugin, int duration, boolean isPermanent, @NotNull UUID pid) Constructor for creating a permanent broom flight effect. -
Method Summary
Modifier and TypeMethodDescriptionvoidsetPermanent(boolean perm) Override default permanent setting for an effect.Methods inherited from class net.pottercraft.ollivanders2.effect.FLYING
checkEffect, doRemoveMethods inherited from class net.pottercraft.ollivanders2.effect.O2Effect
age, getAffectedPlayerText, getInformousText, getLegilimensText, getMaxDuration, getMinDuration, getRemainingDuration, getTargetID, isKilled, isPermanent, kill
-
Constructor Details
-
BROOM_FLYING
public BROOM_FLYING(@NotNull @NotNull Ollivanders2 plugin, int duration, boolean isPermanent, @NotNull @NotNull UUID pid) Constructor for creating a permanent broom flight effect.Creates a specialized flight effect optimized for broom-based flight. The duration parameter is accepted for API consistency with other effects but is ignored - broom flight is always permanent. Smoke particle effects are disabled to provide cleaner visuals during broom flight.
- Parameters:
plugin- a callback to the MC pluginduration- ignored - broom flight is always permanentisPermanent- ignored - broom flight is always permanentpid- the unique ID of the player to give broom flight
-
-
Method Details
-
setPermanent
public void setPermanent(boolean perm) Description copied from class:O2EffectOverride default permanent setting for an effect.- Overrides:
setPermanentin classO2Effect- Parameters:
perm- true if this is permanent, false otherwise
-