Class MultiTurnSpecialAttackBase
java.lang.Object
com.pixelmonmod.pixelmon.battles.attacks.EffectBase
com.pixelmonmod.pixelmon.battles.attacks.specialAttacks.multiTurn.MultiTurnSpecialAttackBase
- Direct Known Subclasses:
Bide
,MultiTurnCharge
,PetalDance
,Rollout
,SkyDrop
,Uproar
Base class for multi-turn moves.
-
Field Summary
Fields inherited from class com.pixelmonmod.pixelmon.battles.attacks.EffectBase
modifiers
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
applyEffect
(PixelmonWrapper user, PixelmonWrapper target) Causes various effects during the move.applyEffectDuring
(PixelmonWrapper user, PixelmonWrapper target) Triggers before the move hits the target.void
applyMissEffect
(PixelmonWrapper user, PixelmonWrapper target) Triggers when the move misses.boolean
cantMiss
(PixelmonWrapper user) Determines whether a move cannot miss.void
Decrements the move's turn count by 1.boolean
doesPersist
(PixelmonWrapper user) Returns whether the move lasts multiple turns.int
getTurnCount
(PixelmonWrapper user) Gets the turn count for the user's multi-turn move.boolean
ignoresType
(PixelmonWrapper user) Returns whether the move ignores type immunities.boolean
isCharging
(PixelmonWrapper user, PixelmonWrapper target) Returns whether the multi-turn move is in a charging turn.void
removeEffect
(PixelmonWrapper user, PixelmonWrapper target) Ends the multi-turn move.protected void
setPersists
(PixelmonWrapper user, boolean value) Sets whether the move will continue next turn.void
setTurnCount
(PixelmonWrapper user, int value) Sets the move's turn count.boolean
Returns whether the move should not have PP deducted during the turn.Methods inherited from class com.pixelmonmod.pixelmon.battles.attacks.EffectBase
applyEarlyEffect, applyEffectAfterAllTargets, applyEffectAfterStatus, applyEffectHitOrMiss, applyEffectStart, canHitMultipleTargets, changeChance, checkChance, dealtDamage, dealtDamagePerHit, getChance, getWeightWithChance, isChance, isUser, modifyDamage, modifyPriority, modifyTargets, modifyTypeEffectiveness, modifyTypeEffectiveness, preventsRedirection, setChance, weightEffect
-
Constructor Details
-
MultiTurnSpecialAttackBase
public MultiTurnSpecialAttackBase()Initializes the multi-turn effect.
-
-
Method Details
-
getTurnCount
Gets the turn count for the user's multi-turn move.- Parameters:
user
- The move's user.- Returns:
- The turn count.
-
decrementTurnCount
Decrements the move's turn count by 1.- Parameters:
user
- The move's user.
-
setTurnCount
Sets the move's turn count.- Parameters:
user
- The move's user.value
- The new turn count.
-
doesPersist
Description copied from class:EffectBase
Returns whether the move lasts multiple turns.- Overrides:
doesPersist
in classEffectBase
- Parameters:
user
- The move's user.- Returns:
- Whether the move lasts multiple turns.
-
setPersists
Sets whether the move will continue next turn.- Parameters:
user
- The move's user.value
- Whether the move will continue next turn.
-
applyEffectDuring
Triggers before the move hits the target.- Parameters:
user
- The move's user.target
- The move's target.- Returns:
- The result of them move.
- Throws:
Exception
-
applyEffect
Description copied from class:EffectBase
Causes various effects during the move.- Specified by:
applyEffect
in classEffectBase
- Parameters:
user
- The move's user.target
- The move's target.
-
cantMiss
Description copied from class:EffectBase
Determines whether a move cannot miss.- Specified by:
cantMiss
in classEffectBase
- Parameters:
user
- The move's user.- Returns:
- Whether the move can't miss.
-
applyMissEffect
Description copied from class:EffectBase
Triggers when the move misses.- Overrides:
applyMissEffect
in classEffectBase
- Parameters:
user
- The move's user.target
- The move's target.
-
ignoresType
Returns whether the move ignores type immunities.- Parameters:
user
- The move's user- Returns:
- Whether the move ignores type immunities
-
removeEffect
Ends the multi-turn move.- Parameters:
user
- The move's usertarget
- The move's target
-
isCharging
Returns whether the multi-turn move is in a charging turn.- Parameters:
user
- The move's usertarget
- The move's target- Returns:
- Whether the multi-turn move is in a charging turn
-
shouldNotLosePP
Returns whether the move should not have PP deducted during the turn.- Parameters:
user
- The move's user.- Returns:
- True if the move should not have PP deducted during the turn
-