Made EFFECT_WRING_OUT read the max power from the move's argument field (#4180)
* Made EFFECT_WRING_OUT read the max power from the move's argument field * Renamed EFFECT_WRING_OUT to EFFECT_VARY_POWER_BASED_ON_HP
This commit is contained in:
parent
de0f94406a
commit
e73c58ed2e
5 changed files with 11 additions and 8 deletions
|
@ -178,7 +178,7 @@ enum {
|
|||
EFFECT_PLEDGE,
|
||||
EFFECT_FLING,
|
||||
EFFECT_NATURAL_GIFT,
|
||||
EFFECT_WRING_OUT,
|
||||
EFFECT_VARY_POWER_BASED_ON_HP,
|
||||
EFFECT_ASSURANCE,
|
||||
EFFECT_TRUMP_CARD,
|
||||
EFFECT_ACROBATICS,
|
||||
|
|
|
@ -451,7 +451,7 @@ static u8 GetMaxPowerTier(u16 move)
|
|||
case EFFECT_GYRO_BALL:
|
||||
return MAX_POWER_TIER_5;
|
||||
case EFFECT_MAGNITUDE:
|
||||
case EFFECT_WRING_OUT:
|
||||
case EFFECT_VARY_POWER_BASED_ON_HP:
|
||||
return MAX_POWER_TIER_6;
|
||||
case EFFECT_FLAIL:
|
||||
case EFFECT_LOW_KICK:
|
||||
|
|
|
@ -8504,8 +8504,8 @@ static inline u32 CalcMoveBasePower(u32 move, u32 battlerAtk, u32 battlerDef, u3
|
|||
if ((gBattleMons[battlerDef].status1 | (STATUS1_SLEEP * (abilityDef == ABILITY_COMATOSE))) & gMovesInfo[move].argument)
|
||||
basePower *= 2;
|
||||
break;
|
||||
case EFFECT_WRING_OUT:
|
||||
basePower = 120 * gBattleMons[battlerDef].hp / gBattleMons[battlerDef].maxHP;
|
||||
case EFFECT_VARY_POWER_BASED_ON_HP:
|
||||
basePower = gMovesInfo[move].argument * gBattleMons[battlerDef].hp / gBattleMons[battlerDef].maxHP;
|
||||
break;
|
||||
case EFFECT_ASSURANCE:
|
||||
if (gProtectStructs[battlerDef].physicalDmg != 0 || gProtectStructs[battlerDef].specialDmg != 0 || gProtectStructs[battlerDef].confusionSelfDmg)
|
||||
|
|
|
@ -1145,7 +1145,7 @@ const struct BattleMoveEffect gBattleMoveEffects[NUM_BATTLE_MOVE_EFFECTS] =
|
|||
.encourageEncore = TRUE,
|
||||
},
|
||||
|
||||
[EFFECT_WRING_OUT] =
|
||||
[EFFECT_VARY_POWER_BASED_ON_HP] =
|
||||
{
|
||||
.battleScript = BattleScript_EffectHit,
|
||||
.battleTvScore = 0, // TODO: Assign points
|
||||
|
|
|
@ -9201,7 +9201,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
|
|||
{
|
||||
.name = COMPOUND_STRING("Wring Out"),
|
||||
.description = sWringOutDescription,
|
||||
.effect = EFFECT_WRING_OUT,
|
||||
.effect = EFFECT_VARY_POWER_BASED_ON_HP,
|
||||
.power = 1,
|
||||
.type = TYPE_NORMAL,
|
||||
.accuracy = 100,
|
||||
|
@ -9209,6 +9209,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
|
|||
.target = MOVE_TARGET_SELECTED,
|
||||
.priority = 0,
|
||||
.category = DAMAGE_CATEGORY_SPECIAL,
|
||||
.argument = 120,
|
||||
.makesContact = TRUE,
|
||||
.contestEffect = CONTEST_EFFECT_STARTLE_PREV_MON,
|
||||
.contestCategory = CONTEST_CATEGORY_SMART,
|
||||
|
@ -11206,7 +11207,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
|
|||
{
|
||||
.name = COMPOUND_STRING("Crush Grip"),
|
||||
.description = sWringOutDescription,
|
||||
.effect = EFFECT_WRING_OUT,
|
||||
.effect = EFFECT_VARY_POWER_BASED_ON_HP,
|
||||
.power = 1,
|
||||
.type = TYPE_NORMAL,
|
||||
.accuracy = 100,
|
||||
|
@ -11214,6 +11215,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
|
|||
.target = MOVE_TARGET_SELECTED,
|
||||
.priority = 0,
|
||||
.category = DAMAGE_CATEGORY_PHYSICAL,
|
||||
.argument = 120,
|
||||
.makesContact = TRUE,
|
||||
.contestEffect = CONTEST_EFFECT_BADLY_STARTLE_FRONT_MON,
|
||||
.contestCategory = CONTEST_CATEGORY_TOUGH,
|
||||
|
@ -19866,7 +19868,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
|
|||
{
|
||||
.name = COMPOUND_STRING("Hard Press"),
|
||||
.description = sWringOutDescription,
|
||||
.effect = EFFECT_WRING_OUT,
|
||||
.effect = EFFECT_VARY_POWER_BASED_ON_HP,
|
||||
.power = 1,
|
||||
.type = TYPE_STEEL,
|
||||
.accuracy = 100,
|
||||
|
@ -19874,6 +19876,7 @@ const struct MoveInfo gMovesInfo[MOVES_COUNT_DYNAMAX] =
|
|||
.target = MOVE_TARGET_SELECTED,
|
||||
.priority = 0,
|
||||
.category = DAMAGE_CATEGORY_PHYSICAL,
|
||||
.argument = 100,
|
||||
.makesContact = TRUE,
|
||||
},
|
||||
|
||||
|
|
Loading…
Reference in a new issue