mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-28 12:44:18 +01:00
coaching, lash out, burning jealousy
This commit is contained in:
parent
dd51edd881
commit
a37acb8345
@ -13995,7 +13995,7 @@ Move_SKITTER_SMACK::
|
||||
end @to do:
|
||||
|
||||
Move_BURNING_JEALOUSY::
|
||||
end @to do:
|
||||
goto Move_OVERHEAT
|
||||
|
||||
Move_LASH_OUT::
|
||||
end @to do:
|
||||
|
@ -367,6 +367,36 @@ gBattleScriptsForMoveEffects:: @ 82D86A8
|
||||
.4byte BattleScript_EffectSleepHit
|
||||
.4byte BattleScript_EffectEerieSpell
|
||||
.4byte BattleScript_EffectJungleHealing
|
||||
.4byte BattleScript_EffectCoaching
|
||||
.4byte BattleScript_EffectLashOut
|
||||
|
||||
BattleScript_EffectCoaching:
|
||||
attackcanceler
|
||||
attackstring
|
||||
ppreduce
|
||||
jumpifnoally BS_ATTACKER, BattleScript_ButItFailed
|
||||
copybyte gBattlerTarget, gBattlerAttacker
|
||||
setallytonexttarget EffectCoaching_CheckAllyStats
|
||||
goto BattleScript_ButItFailed
|
||||
EffectCoaching_CheckAllyStats:
|
||||
jumpifstat BS_TARGET, CMP_NOT_EQUAL, STAT_ATK, 12, BattleScript_CoachingWorks
|
||||
jumpifstat BS_TARGET, CMP_NOT_EQUAL, STAT_DEF, 12, BattleScript_CoachingWorks
|
||||
goto BattleScript_ButItFailed @ ally at max atk, def
|
||||
BattleScript_CoachingWorks:
|
||||
setbyte sSTAT_ANIM_PLAYED, FALSE
|
||||
playstatchangeanimation BS_TARGET, BIT_ATK | BIT_DEF, 0x0
|
||||
setstatchanger STAT_ATK, 1, FALSE
|
||||
statbuffchange STAT_BUFF_ALLOW_PTR | STAT_BUFF_NOT_PROTECT_AFFECTED, BattleScript_CoachingBoostDef
|
||||
jumpifbyte CMP_EQUAL, cMULTISTRING_CHOOSER, 0x2, BattleScript_CoachingBoostDef
|
||||
printfromtable gStatUpStringIds
|
||||
waitmessage 0x40
|
||||
BattleScript_CoachingBoostDef:
|
||||
setstatchanger STAT_DEF, 1, FALSE
|
||||
statbuffchange STAT_BUFF_ALLOW_PTR | STAT_BUFF_NOT_PROTECT_AFFECTED, BattleScript_MoveEnd
|
||||
jumpifbyte CMP_EQUAL, cMULTISTRING_CHOOSER, 0x2, BattleScript_MoveEnd
|
||||
printfromtable gStatUpStringIds
|
||||
waitmessage 0x40
|
||||
goto BattleScript_MoveEnd
|
||||
|
||||
BattleScript_EffectJungleHealing:
|
||||
attackcanceler
|
||||
@ -2082,6 +2112,7 @@ BattleScript_EffectChangeTypeOnItem:
|
||||
BattleScript_EffectFusionCombo:
|
||||
BattleScript_EffectRevelationDance:
|
||||
BattleScript_EffectBelch:
|
||||
BattleScript_EffectLashOut:
|
||||
|
||||
BattleScript_HitFromAtkCanceler::
|
||||
attackcanceler
|
||||
|
@ -144,6 +144,8 @@ struct ProtectStruct
|
||||
u32 specialDmg;
|
||||
u8 physicalBattlerId;
|
||||
u8 specialBattlerId;
|
||||
u8 statFell:1; // placed here since cleared at end of round
|
||||
u8 statRaised:1;
|
||||
};
|
||||
|
||||
struct SpecialStatus
|
||||
|
@ -342,7 +342,8 @@
|
||||
#define MOVE_EFFECT_THROAT_CHOP 0x43
|
||||
#define MOVE_EFFECT_INCINERATE 0x44
|
||||
#define MOVE_EFFECT_BUG_BITE 0x45
|
||||
#define NUM_MOVE_EFFECTS 0x46
|
||||
#define MOVE_EFFECT_BURNING_JEALOUSY 0x46
|
||||
#define NUM_MOVE_EFFECTS 0x47
|
||||
|
||||
#define MOVE_EFFECT_AFFECTS_USER 0x4000
|
||||
#define MOVE_EFFECT_CERTAIN 0x8000
|
||||
|
@ -353,5 +353,7 @@
|
||||
#define EFFECT_SLEEP_HIT 347 // Relic Song
|
||||
#define EFFECT_EERIE_SPELL 348
|
||||
#define EFFECT_JUNGLE_HEALING 349
|
||||
#define EFFECT_COACHING 350
|
||||
#define EFFECT_LASH_OUT 351
|
||||
|
||||
#endif // GUARD_CONSTANTS_BATTLE_MOVE_EFFECTS_H
|
||||
|
@ -2506,6 +2506,9 @@ void SetMoveEffect(bool32 primary, u32 certain)
|
||||
statusChanged = TRUE;
|
||||
break;
|
||||
case STATUS1_BURN:
|
||||
if (gCurrentMove == MOVE_BURNING_JEALOUSY && gProtectStructs[gEffectBattler].statRaised == 0)
|
||||
break;
|
||||
|
||||
if (GetBattlerAbility(gEffectBattler) == ABILITY_WATER_VEIL
|
||||
&& (primary == TRUE || certain == MOVE_EFFECT_CERTAIN))
|
||||
{
|
||||
@ -9092,9 +9095,14 @@ static u32 ChangeStatBuffs(s8 statValue, u32 statId, u32 flags, const u8 *BS_ptr
|
||||
gBattleTextBuff2[index] = B_BUFF_EOS;
|
||||
|
||||
if (gBattleMons[gActiveBattler].statStages[statId] == MIN_STAT_STAGE)
|
||||
{
|
||||
gBattleCommunication[MULTISTRING_CHOOSER] = 2;
|
||||
}
|
||||
else
|
||||
{
|
||||
gBattleCommunication[MULTISTRING_CHOOSER] = (gBattlerTarget == gActiveBattler);
|
||||
gProtectStructs[gActiveBattler].statFell = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
else // stat increase
|
||||
@ -9129,9 +9137,14 @@ static u32 ChangeStatBuffs(s8 statValue, u32 statId, u32 flags, const u8 *BS_ptr
|
||||
gBattleTextBuff2[index] = B_BUFF_EOS;
|
||||
|
||||
if (gBattleMons[gActiveBattler].statStages[statId] == MAX_STAT_STAGE)
|
||||
{
|
||||
gBattleCommunication[MULTISTRING_CHOOSER] = 2;
|
||||
}
|
||||
else
|
||||
{
|
||||
gBattleCommunication[MULTISTRING_CHOOSER] = (gBattlerTarget == gActiveBattler);
|
||||
gProtectStructs[gActiveBattler].statRaised = 1;
|
||||
}
|
||||
}
|
||||
|
||||
gBattleMons[gActiveBattler].statStages[statId] += statValue;
|
||||
|
@ -6686,6 +6686,10 @@ static u16 CalcMoveBasePower(u16 move, u8 battlerAtk, u8 battlerDef)
|
||||
if (gBattleMoves[gLastUsedMove].effect == EFFECT_FUSION_COMBO && move != gLastUsedMove)
|
||||
basePower *= 2;
|
||||
break;
|
||||
case EFFECT_LASH_OUT:
|
||||
if (gProtectStructs[battlerAtk].statFell == 1)
|
||||
basePower *= 2;
|
||||
break;
|
||||
}
|
||||
|
||||
if (basePower == 0)
|
||||
|
@ -11222,12 +11222,12 @@ const struct BattleMove gBattleMoves[MOVES_COUNT] =
|
||||
|
||||
[MOVE_BURNING_JEALOUSY] =
|
||||
{
|
||||
.effect = EFFECT_PLACEHOLDER, //TODO
|
||||
.effect = EFFECT_BURN_HIT,
|
||||
.power = 70,
|
||||
.type = TYPE_FIRE,
|
||||
.accuracy = 100,
|
||||
.pp = 5,
|
||||
.secondaryEffectChance = 0,
|
||||
.secondaryEffectChance = 100,
|
||||
.target = MOVE_TARGET_BOTH,
|
||||
.priority = 0,
|
||||
.flags = FLAG_PROTECT_AFFECTED | FLAG_MIRROR_MOVE_AFFECTED | FLAG_KINGS_ROCK_AFFECTED,
|
||||
@ -11236,7 +11236,7 @@ const struct BattleMove gBattleMoves[MOVES_COUNT] =
|
||||
|
||||
[MOVE_LASH_OUT] =
|
||||
{
|
||||
.effect = EFFECT_PLACEHOLDER, //TODO
|
||||
.effect = EFFECT_LASH_OUT,
|
||||
.power = 75,
|
||||
.type = TYPE_DARK,
|
||||
.accuracy = 100,
|
||||
@ -11278,7 +11278,7 @@ const struct BattleMove gBattleMoves[MOVES_COUNT] =
|
||||
|
||||
[MOVE_COACHING] =
|
||||
{
|
||||
.effect = EFFECT_PLACEHOLDER, //TODO
|
||||
.effect = EFFECT_COACHING,
|
||||
.power = 0,
|
||||
.type = TYPE_FIGHTING,
|
||||
.accuracy = 0,
|
||||
|
Loading…
Reference in New Issue
Block a user