Class Opportunist
java.lang.Object
com.pixelmonmod.pixelmon.api.pokemon.ability.AbstractAbility
com.pixelmonmod.pixelmon.api.pokemon.ability.abilities.Opportunist
- All Implemented Interfaces:
Ability
,RarityTweak
,ITranslatable
If an opponent's stat is boosted, the Pokémon seizes the opportunity to boost the same stat for itself.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
applyEffectOnStatModified
(PixelmonWrapper pw, PixelmonWrapper affected) Triggers when the holder's stats are modified.void
onStatIncrease
(PixelmonWrapper pw, PixelmonWrapper affected, int amount, BattleStatsType stat) Triggers when one of the holder's stats are increased.Methods inherited from class com.pixelmonmod.pixelmon.api.pokemon.ability.AbstractAbility
equals, getName, getNewInstance, getTranslationKey, hashCode
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.pixelmonmod.pixelmon.api.pokemon.ability.Ability
adjustCriticalHitChance, adjustCritStage, allowsAttack, allowsIncomingAttack, allowsIncomingAttackMessage, allowsIncomingAttackTeammate, allowsOutgoingAttack, allowsStatChange, allowsStatChangeTeammate, allowsStatus, allowsStatusOpponent, allowsStatusTeammate, alwaysConsideredDamaged, applyAllySwitchInEffect, applyCritMultiplier, applyDynamaxEffect, applyEffectOnContactTarget, applyEffectOnContactTargetLate, applyEffectOnContactUser, applyEndOfBattleEffect, applyFoeSwitchInEffect, applyPostSwitchEffect, applyRepeatedEffect, applyRepeatedEffectAfterStatus, applyStartOfBattleEffect, applyStartOfBattleHeadOfPartyEffect, applyStartOfTurnEffect, applySwitchInEffect, applySwitchOutEffect, applySwitchReplaceEffect, beforeSwitch, canAttackThisTurn, canBeCopied, canBeDisabled, canBeEntrained, canBeIgnored, canBeReceived, canBeRoleplayed, canBeSwapped, canBeTraced, canPerish, doesAttackUserIgnoreProtect, doesContactAttackMakeContact, getMultiplier, ignoreEvasion, ignoresStatusTypeImmunity, ignoreWeather, isAbility, isAbility, isAbility, isAbility, isAbility, isNegativeAbility, modifyConfusionDamage, modifyDamage, modifyDamageIncludeFixed, modifyDamageTarget, modifyDamageTeammate, modifyDamageUser, modifyEffectiveTypes, modifyMoveEffectChanceTarget, modifyMoveEffectChanceUser, modifyMoveEffects, modifyPowerAndAccuracyTarget, modifyPowerAndAccuracyTeammate, modifyPowerAndAccuracyUser, modifyPriority, modifySelfDamage, modifyStab, modifyStats, modifyStatsCancellable, modifyStatsCancellableOther, modifyStatsCancellableTeammate, modifyStatsOther, modifyStatsTeammate, modifyType, modifyWeight, needNewInstance, onAbilityLost, onAllyFaint, onBerryEaten, onDamageReceived, onFoeFaint, onHealed, onItemChanged, onItemConsumed, onSelfFaint, onStatDecrease, onStatusAdded, onTerrainSwitch, onWeatherChange, postProcessAttack, postProcessAttackOther, postProcessAttackUser, postProcessAttackUserHitOrMiss, preProcessAttack, preProcessAttackStatBeforeDamageCalc, preProcessAttackUser, preventsCriticalHits, preventsItemRemoval, preventsRedirection, redirectAttack, sendActivatedMessage, startMove, stopsForcedSwitches, stopsSwitching, tookDamageTarget, tookDamageTargetAfterMove, tookDamageUser, worksWithTransformedPokemon
Methods inherited from interface com.pixelmonmod.pixelmon.api.util.ITranslatable
getLocalizedName, getTranslatedName
-
Constructor Details
-
Opportunist
public Opportunist()
-
-
Method Details
-
onStatIncrease
public void onStatIncrease(PixelmonWrapper pw, PixelmonWrapper affected, int amount, BattleStatsType stat) Description copied from interface:Ability
Triggers when one of the holder's stats are increased.- Parameters:
pw
- The Pokémon whose ability it is.affected
- The Pokémon whose stat was increased.amount
- The size of the increase.stat
- The stat that was increased.
-
applyEffectOnStatModified
Description copied from interface:Ability
Triggers when the holder's stats are modified. Fired after onStatIncrease and onStatDecrease fire for each stat change.- Parameters:
pw
- The Pokémon whose ability it is.affected
- The Pokémon whose stats were just modified.
-