Class SpellFieldComponent.Builder
java.lang.Object
johnsmith.enchantmentcore.api.enchantment.spellfield.SpellFieldComponent.Builder
- Enclosing class:
SpellFieldComponent
Fluent builder for assembling a
SpellFieldComponent programmatically.-
Method Summary
Modifier and TypeMethodDescriptionaddBlockEffect(SpellFieldBlockEffect effect) Appends a block-targeted effect to the spell field.Appends an entity-targeted effect to the spell field.Appends a visual/particle effect to the spell field.addVolume(SpellFieldVolume volume) Appends a spatial volume definition to the spell field.Appends a volume-wide effect to the spell field.build()Returns the constructedSpellFieldComponent.
-
Method Details
-
addVolume
Appends a spatial volume definition to the spell field.- Parameters:
volume- TheSpellFieldVolumeto add.- Returns:
- This builder for chaining.
-
addEntityEffect
Appends an entity-targeted effect to the spell field.- Parameters:
effect- TheSpellFieldEntityEffectto add.- Returns:
- This builder for chaining.
-
addBlockEffect
Appends a block-targeted effect to the spell field.- Parameters:
effect- TheSpellFieldBlockEffectto add.- Returns:
- This builder for chaining.
-
addVolumeEffect
Appends a volume-wide effect to the spell field.- Parameters:
effect- TheSpellFieldVolumeEffectto add.- Returns:
- This builder for chaining.
-
addVisualEffect
Appends a visual/particle effect to the spell field.- Parameters:
effect- TheSpellFieldVisualEffectto add.- Returns:
- This builder for chaining.
-
build
Returns the constructedSpellFieldComponent.- Returns:
- The built
SpellFieldComponentinstance.
-