Class HiddenPower
java.lang.Object
com.pixelmonmod.pixelmon.battles.attacks.EffectBase
com.pixelmonmod.pixelmon.battles.attacks.specialAttacks.basic.SpecialAttackBase
com.pixelmonmod.pixelmon.battles.attacks.specialAttacks.basic.HiddenPower
Changes type and power depending on the Pokémon's IVs.
-
Field Summary
Fields inherited from class com.pixelmonmod.pixelmon.battles.attacks.EffectBase
modifiers
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionapplyEffectStart
(PixelmonWrapper user, PixelmonWrapper target) Causes effects before the move's power is calculated.static int
calculateFedbca
(int[] ivs) static int[]
calculateOptimalIVs
(Element type, int[] initialIVs, boolean[] requiredIVs) static Element
getHiddenPowerType
(int... ivs) Gets Hidden Power's type based on IVs.static Element
getHiddenPowerType
(Pokemon pokemon, IVStore ivs, String reason) Gets Hidden Power's type based on IVs.static Element
Gets Hidden Power's type based on IVs.static IVStore
getOptimalIVs
(Element type) Gets the optimal IVs for a maximum-power Hidden Power of a certain type.static void
Methods inherited from class com.pixelmonmod.pixelmon.battles.attacks.specialAttacks.basic.SpecialAttackBase
applyAfterEffect, applyEffect, applyEffectDuring, cantMiss, ignoresWeather, modifyPriority, overridesDefendingStat, shouldThawUser
Methods inherited from class com.pixelmonmod.pixelmon.battles.attacks.EffectBase
applyEarlyEffect, applyEffectAfterAllTargets, applyEffectAfterStatus, applyEffectHitOrMiss, applyMissEffect, canHitMultipleTargets, changeChance, checkChance, dealtDamage, dealtDamagePerHit, doesPersist, getChance, getWeightWithChance, isChance, isUser, modifyDamage, modifyPriority, modifyTargets, modifyTypeEffectiveness, modifyTypeEffectiveness, preventsRedirection, setChance, weightEffect
-
Constructor Details
-
HiddenPower
public HiddenPower()
-
-
Method Details
-
applyEffectStart
Description copied from class:EffectBase
Causes effects before the move's power is calculated.- Overrides:
applyEffectStart
in classEffectBase
- Parameters:
user
- The move's user.target
- The move's target.- Returns:
- The result of the effect.
-
getHiddenPowerType
Gets Hidden Power's type based on IVs.- Parameters:
ivs
- The IVs to calculate Hidden Power's type with.- Returns:
- Hidden Power's type based on the given IVs.
-
getHiddenPowerType
Gets Hidden Power's type based on IVs.- Parameters:
ivs
- The IVs to calculate Hidden Power's type with.- Returns:
- Hidden Power's type based on the given IVs.
-
getHiddenPowerType
Gets Hidden Power's type based on IVs.- Parameters:
ivs
- The IVs to calculate Hidden Power's type with.- Returns:
- Hidden Power's type based on the given IVs.
-
calculateFedbca
public static int calculateFedbca(int[] ivs) -
getOptimalIVs
Gets the optimal IVs for a maximum-power Hidden Power of a certain type.- Parameters:
type
- The type that Hidden Power has to be.- Returns:
- The optimal IVs for a maximum-power Hidden Power of the specified type.
-
main
-
calculateOptimalIVs
-