mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2025-01-14 15:43:43 +01:00
Slow Start
This commit is contained in:
parent
b5ba1de7cf
commit
a2813e63de
@ -5741,6 +5741,14 @@ BattleScript_ThroatChopEndTurn::
|
|||||||
printstring STRINGID_THROATCHOPENDS
|
printstring STRINGID_THROATCHOPENDS
|
||||||
waitmessage 0x40
|
waitmessage 0x40
|
||||||
end2
|
end2
|
||||||
|
|
||||||
|
BattleScript_SlowStartEnds::
|
||||||
|
pause 0x5
|
||||||
|
copybyte gBattlerAbility, gBattlerAttacker
|
||||||
|
call BattleScript_AbilityPopUp
|
||||||
|
printstring STRINGID_SLOWSTARTEND
|
||||||
|
waitmessage 0x40
|
||||||
|
end2
|
||||||
|
|
||||||
BattleScript_SelectingNotAllowedMoveGravity::
|
BattleScript_SelectingNotAllowedMoveGravity::
|
||||||
printselectionstring STRINGID_GRAVITYPREVENTSUSAGE
|
printselectionstring STRINGID_GRAVITYPREVENTSUSAGE
|
||||||
|
@ -331,5 +331,6 @@ extern const u8 BattleScript_AftermathDmg[];
|
|||||||
extern const u8 BattleScript_StanceChangeActivates[];
|
extern const u8 BattleScript_StanceChangeActivates[];
|
||||||
extern const u8 BattleScript_DisguiseBustedActivates[];
|
extern const u8 BattleScript_DisguiseBustedActivates[];
|
||||||
extern const u8 BattleScript_AnticipationActivates[];
|
extern const u8 BattleScript_AnticipationActivates[];
|
||||||
|
extern const u8 BattleScript_SlowStartEnds[];
|
||||||
|
|
||||||
#endif // GUARD_BATTLE_SCRIPTS_H
|
#endif // GUARD_BATTLE_SCRIPTS_H
|
||||||
|
@ -4254,6 +4254,8 @@ u32 GetBattlerTotalSpeedStat(u8 battlerId)
|
|||||||
speed = (speed * 150) / 100;
|
speed = (speed * 150) / 100;
|
||||||
else if (ability == ABILITY_SURGE_SURFER && gFieldStatuses & STATUS_FIELD_ELECTRIC_TERRAIN)
|
else if (ability == ABILITY_SURGE_SURFER && gFieldStatuses & STATUS_FIELD_ELECTRIC_TERRAIN)
|
||||||
speed *= 2;
|
speed *= 2;
|
||||||
|
else if (ability == ABILITY_SLOW_START && gDisableStructs[battlerId].slowStartTimer != 0)
|
||||||
|
speed /= 2;
|
||||||
|
|
||||||
// stat stages
|
// stat stages
|
||||||
speed *= gStatStageRatios[gBattleMons[battlerId].statStages[STAT_SPEED]][0];
|
speed *= gStatStageRatios[gBattleMons[battlerId].statStages[STAT_SPEED]][0];
|
||||||
|
@ -584,7 +584,7 @@ static const u8 sText_MoldBreakerEnters[] = _("{B_ATK_NAME_WITH_PREFIX} breaks t
|
|||||||
static const u8 sText_TeravoltEnters[] = _("{B_ATK_NAME_WITH_PREFIX} is radiating a bursting aura!");
|
static const u8 sText_TeravoltEnters[] = _("{B_ATK_NAME_WITH_PREFIX} is radiating a bursting aura!");
|
||||||
static const u8 sText_TurboblazeEnters[] = _("{B_ATK_NAME_WITH_PREFIX} is radiating\na blazing aura!");
|
static const u8 sText_TurboblazeEnters[] = _("{B_ATK_NAME_WITH_PREFIX} is radiating\na blazing aura!");
|
||||||
static const u8 sText_SlowStartEnters[] = _("{B_ATK_NAME_WITH_PREFIX} can't get it going!");
|
static const u8 sText_SlowStartEnters[] = _("{B_ATK_NAME_WITH_PREFIX} can't get it going!");
|
||||||
static const u8 sText_SlowStartEnd[] = _("{B_ATK_NAME_WITH_PREFIX} finally got its act together!");
|
static const u8 sText_SlowStartEnd[] = _("{B_ATK_NAME_WITH_PREFIX} finally got\nits act together!");
|
||||||
static const u8 sText_SolarPowerHpDrop[] = _("The {B_ATK_NAME_WITH_PREFIX}'s {B_ATK_ABILITY}\ntakes its toll!");
|
static const u8 sText_SolarPowerHpDrop[] = _("The {B_ATK_NAME_WITH_PREFIX}'s {B_ATK_ABILITY}\ntakes its toll!");
|
||||||
static const u8 sText_AftermathDmg[] = _("{B_ATK_NAME_WITH_PREFIX} is hurt!");
|
static const u8 sText_AftermathDmg[] = _("{B_ATK_NAME_WITH_PREFIX} is hurt!");
|
||||||
static const u8 sText_AnticipationActivates[] = _("{B_ATK_NAME_WITH_PREFIX} shuddered\nin anticipation!");
|
static const u8 sText_AnticipationActivates[] = _("{B_ATK_NAME_WITH_PREFIX} shuddered\nin anticipation!");
|
||||||
|
@ -1392,6 +1392,7 @@ enum
|
|||||||
ENDTURN_ELECTRIFY,
|
ENDTURN_ELECTRIFY,
|
||||||
ENDTURN_POWDER,
|
ENDTURN_POWDER,
|
||||||
ENDTURN_THROAT_CHOP,
|
ENDTURN_THROAT_CHOP,
|
||||||
|
ENDTURN_SLOW_START,
|
||||||
ENDTURN_BATTLER_COUNT
|
ENDTURN_BATTLER_COUNT
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -1856,6 +1857,16 @@ u8 DoBattlerEndTurnEffects(void)
|
|||||||
}
|
}
|
||||||
gBattleStruct->turnEffectsTracker++;
|
gBattleStruct->turnEffectsTracker++;
|
||||||
break;
|
break;
|
||||||
|
case ENDTURN_SLOW_START:
|
||||||
|
if (gDisableStructs[gActiveBattler].slowStartTimer
|
||||||
|
&& --gDisableStructs[gActiveBattler].slowStartTimer == 0
|
||||||
|
&& ability == ABILITY_SLOW_START)
|
||||||
|
{
|
||||||
|
BattleScriptExecute(BattleScript_SlowStartEnds);
|
||||||
|
effect++;
|
||||||
|
}
|
||||||
|
gBattleStruct->turnEffectsTracker++;
|
||||||
|
break;
|
||||||
case ENDTURN_BATTLER_COUNT: // done
|
case ENDTURN_BATTLER_COUNT: // done
|
||||||
gBattleStruct->turnEffectsTracker = 0;
|
gBattleStruct->turnEffectsTracker = 0;
|
||||||
gBattleStruct->turnEffectsBattlerId++;
|
gBattleStruct->turnEffectsBattlerId++;
|
||||||
@ -2854,6 +2865,7 @@ u8 AbilityBattleEffects(u8 caseID, u8 battler, u8 ability, u8 special, u16 moveA
|
|||||||
case ABILITY_SLOW_START:
|
case ABILITY_SLOW_START:
|
||||||
if (!gSpecialStatuses[battler].switchInAbilityDone)
|
if (!gSpecialStatuses[battler].switchInAbilityDone)
|
||||||
{
|
{
|
||||||
|
gDisableStructs[battler].slowStartTimer = 5;
|
||||||
gBattleCommunication[MULTISTRING_CHOOSER] = 3;
|
gBattleCommunication[MULTISTRING_CHOOSER] = 3;
|
||||||
gSpecialStatuses[battler].switchInAbilityDone = 1;
|
gSpecialStatuses[battler].switchInAbilityDone = 1;
|
||||||
BattleScriptPushCursorAndCallback(BattleScript_SwitchInAbilityMsg);
|
BattleScriptPushCursorAndCallback(BattleScript_SwitchInAbilityMsg);
|
||||||
|
@ -7296,7 +7296,7 @@ const struct BaseStats gBaseStats[] =
|
|||||||
.growthRate = GROWTH_SLOW,
|
.growthRate = GROWTH_SLOW,
|
||||||
.eggGroup1 = EGG_GROUP_FLYING,
|
.eggGroup1 = EGG_GROUP_FLYING,
|
||||||
.eggGroup2 = EGG_GROUP_FLYING,
|
.eggGroup2 = EGG_GROUP_FLYING,
|
||||||
.abilities = {ABILITY_KEEN_EYE, ABILITY_STURDY},
|
.abilities = {ABILITY_SLOW_START, ABILITY_SLOW_START},
|
||||||
.safariZoneFleeRate = 0,
|
.safariZoneFleeRate = 0,
|
||||||
.bodyColor = BODY_COLOR_GRAY,
|
.bodyColor = BODY_COLOR_GRAY,
|
||||||
.noFlip = FALSE,
|
.noFlip = FALSE,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user