-
-
Field Summary
Fields inherited from interface com.github.minecraftschurlimods.arsmagicalegacy.api.spell.ISpellPart
REGISTRY_KEY
-
Method Summary
invoke(ISpell spell,
net.minecraft.world.entity.LivingEntity caster,
net.minecraft.world.level.Level level,
List<ISpellModifier> modifiers,
@Nullable net.minecraft.world.phys.HitResult hit,
int ticksUsed,
int index,
boolean awardXp)
default boolean
default boolean
default boolean
default boolean
Methods inherited from interface com.github.minecraftschurlimods.arsmagicalegacy.api.spell.ISpellPart
getId
-
Method Details
-
invoke
SpellCastResult invoke(ISpell spell,
net.minecraft.world.entity.LivingEntity caster,
net.minecraft.world.level.Level level,
List<ISpellModifier> modifiers,
@Nullable
@Nullable net.minecraft.world.phys.HitResult hit,
int ticksUsed,
int index,
boolean awardXp)
Casts the spell.
- Parameters:
spell - The spell that is cast.
caster - The player that casts the spell.
level - The level that the caster is in.
modifiers - A list of modifiers that affect this spell cast.
hit - The target of the spell.
ticksUsed - The amount of ticks this spell has been cast already.
index - The index of the next component.
awardXp - Whether to grant the player magic xp or not.
- Returns:
- A SpellCastResult that represents the spell casting outcome.
-
getStatsUsed
- Returns:
- A set containing all spell part stats that affect this shape.
-
isContinuous
default boolean isContinuous()
- Returns:
- Whether the shape is continuous or not.
-
isEndShape
default boolean isEndShape()
- Returns:
- True if this shape can only be at the end, false otherwise.
-
needsPrecedingShape
default boolean needsPrecedingShape()
- Returns:
- True if this shape can not be at the beginning, false otherwise.
-
needsToComeFirst
default boolean needsToComeFirst()
- Returns:
- True if this shape can only be at the beginning, false otherwise.
-
getType
- Specified by:
getType in interface ISpellPart
- Returns:
- The type of this spell part.