Merge branch '_RHH/master' into _RHH/upcoming
# Conflicts: # asm/macros/battle_anim_script.inc # data/battle_anim_scripts.s # include/constants/battle_anim.h # src/battle_anim.c # src/data/battle_anim.h
22
INSTALL.md
|
@ -33,27 +33,23 @@ WSL1 is the preferred terminal to build **pokeemerald Expansion**. The following
|
|||
- Otherwise, **open WSL** and go to [Choosing where to store pokeemerald Expansion (WSL1)](#Choosing-where-to-store-pokeemerald-expansion-WSL1).
|
||||
|
||||
### Installing WSL1
|
||||
1. Open [Windows Powershell **as Administrator**](https://i.imgur.com/QKmVbP9.png), and run the following command (Right Click or Shift+Insert is paste in the Powershell).
|
||||
1. Open [Windows Powershell **as Administrator**](https://i.imgur.com/QKmVbP9.png), and run the following commands (Right Click or Shift+Insert is paste in the Powershell).
|
||||
|
||||
```powershell
|
||||
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
|
||||
wsl --install -d Ubuntu --enable-wsl1
|
||||
```
|
||||
|
||||
2. Once the process finishes, restart your machine.
|
||||
|
||||
3. The next step is to choose and install a Linux distribution from the Microsoft Store. The following instructions will assume Ubuntu as the Linux distribution of choice.
|
||||
3. Open Windows Powershell **as Administrator** again (after restarting), and run the following command to configure Ubuntu to use WSL1.
|
||||
|
||||
```powershell
|
||||
wsl --set-version Ubuntu 1
|
||||
```
|
||||
<details>
|
||||
<summary><i>Note for advanced users...</i></summary>
|
||||
<summary><i>Note...</i></summary>
|
||||
|
||||
> You can pick a preferred Linux distribution, but setup instructions may differ. Debian should work with the given instructions, but has not been tested.
|
||||
</details>
|
||||
|
||||
4. Open the [Microsoft Store Linux Selection](https://aka.ms/wslstore), click Ubuntu, then click Get, which will install the Ubuntu distribution.
|
||||
<details>
|
||||
<summary><i>Notes...</i></summary>
|
||||
|
||||
> Note 1: If a dialog pops up asking for you to sign into a Microsoft Account, then just close the dialog.
|
||||
> Note 2: If the link does not work, then open the Microsoft Store manually, and search for the Ubuntu app (choose the one with no version number).
|
||||
> WSL may open automatically after restarting, but you can ignore it for now.
|
||||
</details>
|
||||
|
||||
### Setting up WSL1
|
||||
|
|
|
@ -315,8 +315,14 @@
|
|||
.Lsprite_\@_2:
|
||||
.endm
|
||||
|
||||
.macro createdragondartsprite anim_battler:req, subpriority_offset:req, argv:vararg
|
||||
.macro jumpifmovetypeequal type:req, jumpInstr:req
|
||||
.byte 0x33
|
||||
.byte \type
|
||||
.4byte \jumpInstr
|
||||
.endm
|
||||
|
||||
.macro createdragondartsprite anim_battler:req, subpriority_offset:req, argv:vararg
|
||||
.byte 0x34
|
||||
.if \anim_battler == ANIM_TARGET
|
||||
.byte ANIMSPRITE_IS_TARGET | (\subpriority_offset & 0x7F)
|
||||
.else
|
||||
|
|
|
@ -16900,6 +16900,59 @@ ElectroShotUnleash:
|
|||
blendoff
|
||||
end
|
||||
|
||||
Move_IVY_CUDGEL::
|
||||
loadspritegfx ANIM_TAG_IVY_CUDGEL_GRASS
|
||||
loadspritegfx ANIM_TAG_WOOD_HAMMER
|
||||
loadspritegfx ANIM_TAG_WOOD_HAMMER_HAMMER
|
||||
loadspritegfx ANIM_TAG_IMPACT
|
||||
playsewithpan SE_M_SWAGGER, SOUND_PAN_ATTACKER
|
||||
createvisualtask AnimTask_TranslateMonEllipticalRespectSide, 2, ANIM_ATTACKER, 12, 4, 2, 4
|
||||
jumpifmovetypeequal TYPE_FIRE, IvyCudgelFire
|
||||
jumpifmovetypeequal TYPE_ROCK, IvyCudgelRock
|
||||
jumpifmovetypeequal TYPE_WATER, IvyCudgelWater
|
||||
createsprite gIvyCudgelSpriteTemplate, ANIM_TARGET, 2
|
||||
delay 60
|
||||
createvisualtask AnimTask_ShakeMonInPlace, 2, ANIM_ATTACKER, 3, 0, 12, 4
|
||||
delay 18
|
||||
createvisualtask AnimTask_SquishTarget, 0x2
|
||||
delay 6
|
||||
call WoodHammerImpact
|
||||
waitforvisualfinish
|
||||
end
|
||||
IvyCudgelFire:
|
||||
loadspritegfx ANIM_TAG_IVY_CUDGEL_FIRE
|
||||
createsprite gIvyCudgelFireSpriteTemplate, ANIM_TARGET, 2
|
||||
delay 60
|
||||
createvisualtask AnimTask_ShakeMonInPlace, 2, ANIM_ATTACKER, 3, 0, 12, 4
|
||||
delay 18
|
||||
createvisualtask AnimTask_SquishTarget, 0x2
|
||||
delay 6
|
||||
call WoodHammerImpact
|
||||
waitforvisualfinish
|
||||
end
|
||||
IvyCudgelRock:
|
||||
loadspritegfx ANIM_TAG_IVY_CUDGEL_ROCK
|
||||
createsprite gIvyCudgelRockSpriteTemplate, ANIM_TARGET, 2
|
||||
delay 60
|
||||
createvisualtask AnimTask_ShakeMonInPlace, 2, ANIM_ATTACKER, 3, 0, 12, 4
|
||||
delay 18
|
||||
createvisualtask AnimTask_SquishTarget, 0x2
|
||||
delay 6
|
||||
call WoodHammerImpact
|
||||
waitforvisualfinish
|
||||
end
|
||||
IvyCudgelWater:
|
||||
loadspritegfx ANIM_TAG_IVY_CUDGEL_WATER
|
||||
createsprite gIvyCudgelWaterSpriteTemplate, ANIM_TARGET, 2
|
||||
delay 60
|
||||
createvisualtask AnimTask_ShakeMonInPlace, 2, ANIM_ATTACKER, 3, 0, 12, 4
|
||||
delay 18
|
||||
createvisualtask AnimTask_SquishTarget, 0x2
|
||||
delay 6
|
||||
call WoodHammerImpact
|
||||
waitforvisualfinish
|
||||
end
|
||||
|
||||
Move_SPICY_EXTRACT::
|
||||
loadspritegfx ANIM_TAG_SMALL_EMBER
|
||||
loadspritegfx ANIM_TAG_POISON_BUBBLE
|
||||
|
@ -16975,7 +17028,6 @@ Move_MAGICAL_TORQUE::
|
|||
Move_PSYBLADE::
|
||||
Move_BLOOD_MOON::
|
||||
Move_MATCHA_GOTCHA::
|
||||
Move_IVY_CUDGEL::
|
||||
Move_TERA_STARSTORM::
|
||||
Move_FICKLE_BEAM::
|
||||
Move_THUNDERCLAP::
|
||||
|
|
BIN
graphics/battle_anims/sprites/cudgel.png
Normal file
After Width: | Height: | Size: 319 B |
Before Width: | Height: | Size: 447 B After Width: | Height: | Size: 447 B |
Before Width: | Height: | Size: 537 B After Width: | Height: | Size: 537 B |
Before Width: | Height: | Size: 1,002 B After Width: | Height: | Size: 962 B |
|
@ -2,12 +2,12 @@ JASC-PAL
|
|||
0100
|
||||
15
|
||||
148 209 161
|
||||
0 0 0
|
||||
42 44 41
|
||||
21 158 7
|
||||
0 0 0
|
||||
74 76 73
|
||||
25 27 24
|
||||
61 113 53
|
||||
25 27 24
|
||||
109 99 108
|
||||
133 139 139
|
||||
53 134 168
|
||||
|
|
|
@ -2,12 +2,12 @@ JASC-PAL
|
|||
0100
|
||||
15
|
||||
148 209 161
|
||||
0 0 0
|
||||
42 44 41
|
||||
21 158 7
|
||||
0 0 0
|
||||
74 76 73
|
||||
25 27 24
|
||||
61 113 53
|
||||
25 27 24
|
||||
109 99 108
|
||||
133 139 139
|
||||
53 134 168
|
||||
|
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1 KiB |
Before Width: | Height: | Size: 533 B After Width: | Height: | Size: 533 B |
Before Width: | Height: | Size: 999 B After Width: | Height: | Size: 958 B |
|
@ -2,18 +2,18 @@ JASC-PAL
|
|||
0100
|
||||
16
|
||||
148 210 164
|
||||
156 153 172
|
||||
131 28 24
|
||||
49 133 172
|
||||
213 230 246
|
||||
0 0 0
|
||||
41 44 41
|
||||
16 157 0
|
||||
230 60 49
|
||||
57 113 49
|
||||
49 133 172
|
||||
131 28 24
|
||||
213 230 246
|
||||
255 198 74
|
||||
172 105 32
|
||||
16 157 0
|
||||
57 113 49
|
||||
156 153 172
|
||||
49 190 230
|
||||
0 0 0
|
||||
164 52 49
|
||||
74 76 74
|
||||
189 137 90
|
||||
230 60 49
|
||||
|
|
|
@ -2,18 +2,18 @@ JASC-PAL
|
|||
0100
|
||||
16
|
||||
148 210 164
|
||||
156 153 172
|
||||
131 28 24
|
||||
49 133 172
|
||||
213 230 246
|
||||
0 0 0
|
||||
41 44 41
|
||||
16 157 0
|
||||
230 60 49
|
||||
57 113 49
|
||||
49 133 172
|
||||
131 28 24
|
||||
213 230 246
|
||||
255 198 74
|
||||
124 162 56
|
||||
16 157 0
|
||||
57 113 49
|
||||
156 153 172
|
||||
49 190 230
|
||||
0 0 0
|
||||
164 52 49
|
||||
74 76 74
|
||||
189 137 90
|
||||
230 60 49
|
||||
|
|
|
@ -2,17 +2,17 @@ JASC-PAL
|
|||
0100
|
||||
15
|
||||
148 209 161
|
||||
42 44 41
|
||||
0 1 0
|
||||
27 70 15
|
||||
0 164 153
|
||||
17 106 68
|
||||
42 44 41
|
||||
21 158 7
|
||||
27 70 15
|
||||
61 113 53
|
||||
17 106 68
|
||||
83 133 90
|
||||
74 76 73
|
||||
61 97 53
|
||||
175 216 159
|
||||
251 253 250
|
||||
139 99 57
|
||||
0 164 153
|
||||
120 81 39
|
||||
219 157 92
|
||||
83 133 90
|
||||
|
|
|
@ -2,17 +2,17 @@ JASC-PAL
|
|||
0100
|
||||
15
|
||||
148 209 161
|
||||
42 44 41
|
||||
0 1 0
|
||||
27 70 15
|
||||
0 164 153
|
||||
17 106 68
|
||||
42 44 41
|
||||
21 158 7
|
||||
27 70 15
|
||||
61 113 53
|
||||
17 106 68
|
||||
83 133 90
|
||||
74 76 73
|
||||
61 97 53
|
||||
175 216 159
|
||||
251 253 250
|
||||
139 99 57
|
||||
0 164 153
|
||||
124 162 56
|
||||
219 157 92
|
||||
83 133 90
|
||||
|
|
Before Width: | Height: | Size: 472 B After Width: | Height: | Size: 472 B |
Before Width: | Height: | Size: 1,001 B After Width: | Height: | Size: 960 B |
|
@ -2,12 +2,12 @@ JASC-PAL
|
|||
0100
|
||||
16
|
||||
148 209 161
|
||||
0 0 0
|
||||
42 44 41
|
||||
21 158 7
|
||||
74 76 73
|
||||
0 0 0
|
||||
61 113 53
|
||||
11 64 121
|
||||
61 113 53
|
||||
74 76 73
|
||||
15 90 170
|
||||
0 126 229
|
||||
53 134 168
|
||||
|
|
|
@ -2,12 +2,12 @@ JASC-PAL
|
|||
0100
|
||||
16
|
||||
148 209 161
|
||||
0 0 0
|
||||
42 44 41
|
||||
21 158 7
|
||||
74 76 73
|
||||
0 0 0
|
||||
61 113 53
|
||||
11 64 121
|
||||
61 113 53
|
||||
74 76 73
|
||||
15 90 170
|
||||
0 126 229
|
||||
53 134 168
|
||||
|
|
|
@ -155,7 +155,7 @@ bool32 TryChangeBattleWeather(u32 battler, u32 weatherEnumId, bool32 viaAbility)
|
|||
u32 AbilityBattleEffects(u32 caseID, u32 battler, u32 ability, u32 special, u32 moveArg);
|
||||
bool32 TryPrimalReversion(u32 battler);
|
||||
bool32 IsNeutralizingGasOnField(void);
|
||||
bool32 IsMoldBreakerTypeAbility(u32 ability);
|
||||
bool32 IsMoldBreakerTypeAbility(u32 battler, u32 ability);
|
||||
u32 GetBattlerAbility(u32 battler);
|
||||
u32 IsAbilityOnSide(u32 battler, u32 ability);
|
||||
u32 IsAbilityOnOpposingSide(u32 battler, u32 ability);
|
||||
|
|
|
@ -405,9 +405,13 @@
|
|||
#define ANIM_TAG_SYRUP_SHELL_YELLOW (ANIM_SPRITES_START + 391)
|
||||
#define ANIM_TAG_SYRUP_SPLAT_RED (ANIM_SPRITES_START + 392)
|
||||
#define ANIM_TAG_SYRUP_SPLAT_YELLOW (ANIM_SPRITES_START + 393)
|
||||
#define ANIM_TAG_TERA_CRYSTAL (ANIM_SPRITES_START + 394)
|
||||
#define ANIM_TAG_TERA_SHATTER (ANIM_SPRITES_START + 395)
|
||||
#define ANIM_TAG_DREEPY_SHINY (ANIM_SPRITES_START + 396)
|
||||
#define ANIM_TAG_IVY_CUDGEL_GRASS (ANIM_SPRITES_START + 394)
|
||||
#define ANIM_TAG_IVY_CUDGEL_FIRE (ANIM_SPRITES_START + 395)
|
||||
#define ANIM_TAG_IVY_CUDGEL_ROCK (ANIM_SPRITES_START + 396)
|
||||
#define ANIM_TAG_IVY_CUDGEL_WATER (ANIM_SPRITES_START + 397)
|
||||
#define ANIM_TAG_TERA_CRYSTAL (ANIM_SPRITES_START + 398)
|
||||
#define ANIM_TAG_TERA_SHATTER (ANIM_SPRITES_START + 399)
|
||||
#define ANIM_TAG_DREEPY_SHINY (ANIM_SPRITES_START + 400)
|
||||
|
||||
// battlers
|
||||
#define ANIM_ATTACKER 0
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
#define NUM_FOG_DIAGONAL_SPRITES 20
|
||||
#define NUM_SANDSTORM_SPRITES 20
|
||||
#define NUM_SWIRL_SANDSTORM_SPRITES 5
|
||||
#define NUM_SNOWFLAKE_SPRITES 16
|
||||
|
||||
// Controls how the weather should be changing the screen palettes.
|
||||
#define WEATHER_PAL_STATE_CHANGING_WEATHER 0
|
||||
|
|
|
@ -2873,6 +2873,11 @@ extern const u32 gBattleAnimSpriteGfx_SyrupShell[];
|
|||
extern const u32 gBattleAnimSpriteGfx_SyrupSplat[];
|
||||
extern const u32 gBattleAnimSpritePal_SyrupRed[];
|
||||
extern const u32 gBattleAnimSpritePal_SyrupYellow[];
|
||||
extern const u32 gBattleAnimSpriteGfx_IvyCudgel[];
|
||||
extern const u32 gBattleAnimSpritePal_IvyCudgelGrass[];
|
||||
extern const u32 gBattleAnimSpritePal_IvyCudgelFire[];
|
||||
extern const u32 gBattleAnimSpritePal_IvyCudgelRock[];
|
||||
extern const u32 gBattleAnimSpritePal_IvyCudgelWater[];
|
||||
|
||||
extern const u32 gBattleAnimBgImage_Dark[];
|
||||
extern const u32 gBattleAnimBgImage_Ghost[];
|
||||
|
|
|
@ -1353,7 +1353,7 @@ bool32 DoesBattlerIgnoreAbilityChecks(u32 atkAbility, u32 move)
|
|||
if (AI_THINKING_STRUCT->aiFlags[sBattler_AI] & AI_FLAG_NEGATE_UNAWARE)
|
||||
return FALSE; // AI handicap flag: doesn't understand ability suppression concept
|
||||
|
||||
if (IsMoldBreakerTypeAbility(atkAbility) || gMovesInfo[move].ignoresTargetAbility)
|
||||
if (IsMoldBreakerTypeAbility(sBattler_AI, atkAbility) || gMovesInfo[move].ignoresTargetAbility)
|
||||
return TRUE;
|
||||
|
||||
return FALSE;
|
||||
|
@ -2947,7 +2947,7 @@ bool32 AI_CanBeInfatuated(u32 battlerAtk, u32 battlerDef, u32 defAbility)
|
|||
|
||||
u32 ShouldTryToFlinch(u32 battlerAtk, u32 battlerDef, u32 atkAbility, u32 defAbility, u32 move)
|
||||
{
|
||||
if (((!IsMoldBreakerTypeAbility(AI_DATA->abilities[battlerAtk]) && (defAbility == ABILITY_SHIELD_DUST || defAbility == ABILITY_INNER_FOCUS))
|
||||
if (((!IsMoldBreakerTypeAbility(battlerAtk, AI_DATA->abilities[battlerAtk]) && (defAbility == ABILITY_SHIELD_DUST || defAbility == ABILITY_INNER_FOCUS))
|
||||
|| AI_DATA->holdEffects[battlerDef] == HOLD_EFFECT_COVERT_CLOAK
|
||||
|| DoesSubstituteBlockMove(battlerAtk, battlerDef, move)
|
||||
|| AI_IsSlower(battlerAtk, battlerDef, move))) // Opponent goes first
|
||||
|
@ -2990,7 +2990,7 @@ bool32 ShouldFakeOut(u32 battlerAtk, u32 battlerDef, u32 move)
|
|||
|| AI_DATA->holdEffects[battlerAtk] == HOLD_EFFECT_CHOICE_BAND
|
||||
|| AI_DATA->holdEffects[battlerDef] == HOLD_EFFECT_COVERT_CLOAK
|
||||
|| DoesSubstituteBlockMove(battlerAtk, battlerDef, move)
|
||||
|| (!IsMoldBreakerTypeAbility(AI_DATA->abilities[battlerAtk])
|
||||
|| (!IsMoldBreakerTypeAbility(battlerAtk, AI_DATA->abilities[battlerAtk])
|
||||
&& (AI_DATA->abilities[battlerDef] == ABILITY_SHIELD_DUST || AI_DATA->abilities[battlerDef] == ABILITY_INNER_FOCUS)))
|
||||
return FALSE;
|
||||
|
||||
|
|
|
@ -85,6 +85,7 @@ static void Cmd_stopsound(void);
|
|||
static void Cmd_createvisualtaskontargets(void);
|
||||
static void Cmd_createspriteontargets(void);
|
||||
static void Cmd_createspriteontargets_onpos(void);
|
||||
static void Cmd_jumpifmovetypeequal(void);
|
||||
static void Cmd_createdragondartsprite(void);
|
||||
static void RunAnimScriptCommand(void);
|
||||
static void Task_UpdateMonBg(u8 taskId);
|
||||
|
@ -177,7 +178,8 @@ static void (* const sScriptCmdTable[])(void) =
|
|||
Cmd_createvisualtaskontargets, // 0x30
|
||||
Cmd_createspriteontargets, // 0x31
|
||||
Cmd_createspriteontargets_onpos, // 0x32
|
||||
Cmd_createdragondartsprite, // 0x33
|
||||
Cmd_jumpifmovetypeequal, // 0x33
|
||||
Cmd_createdragondartsprite, // 0x34
|
||||
};
|
||||
|
||||
void ClearBattleAnimationVars(void)
|
||||
|
@ -2141,6 +2143,19 @@ static void Cmd_stopsound(void)
|
|||
sBattleAnimScriptPtr++;
|
||||
}
|
||||
|
||||
static void Cmd_jumpifmovetypeequal(void)
|
||||
{
|
||||
u8 moveType;
|
||||
const u8 *type = sBattleAnimScriptPtr + 1;
|
||||
sBattleAnimScriptPtr += 2;
|
||||
GET_MOVE_TYPE(gCurrentMove, moveType);
|
||||
|
||||
if (*type != moveType)
|
||||
sBattleAnimScriptPtr += 4;
|
||||
else
|
||||
sBattleAnimScriptPtr = T2_READ_PTR(sBattleAnimScriptPtr);
|
||||
}
|
||||
|
||||
static void Cmd_createdragondartsprite(void)
|
||||
{
|
||||
s32 i;
|
||||
|
|
|
@ -2958,6 +2958,50 @@ const struct SpriteTemplate gWoodHammerHammerSpriteTemplate =
|
|||
.callback = AnimWoodHammerHammer,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gIvyCudgelSpriteTemplate =
|
||||
{
|
||||
.tileTag = ANIM_TAG_IVY_CUDGEL_GRASS,
|
||||
.paletteTag = ANIM_TAG_IVY_CUDGEL_GRASS,
|
||||
.oam = &gOamData_AffineDouble_ObjNormal_64x64,
|
||||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gWoodHammerHammerAffineAnims,
|
||||
.callback = AnimWoodHammerHammer,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gIvyCudgelFireSpriteTemplate =
|
||||
{
|
||||
.tileTag = ANIM_TAG_IVY_CUDGEL_GRASS,
|
||||
.paletteTag = ANIM_TAG_IVY_CUDGEL_FIRE,
|
||||
.oam = &gOamData_AffineDouble_ObjNormal_64x64,
|
||||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gWoodHammerHammerAffineAnims,
|
||||
.callback = AnimWoodHammerHammer,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gIvyCudgelRockSpriteTemplate =
|
||||
{
|
||||
.tileTag = ANIM_TAG_IVY_CUDGEL_GRASS,
|
||||
.paletteTag = ANIM_TAG_IVY_CUDGEL_ROCK,
|
||||
.oam = &gOamData_AffineDouble_ObjNormal_64x64,
|
||||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gWoodHammerHammerAffineAnims,
|
||||
.callback = AnimWoodHammerHammer,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gIvyCudgelWaterSpriteTemplate =
|
||||
{
|
||||
.tileTag = ANIM_TAG_IVY_CUDGEL_GRASS,
|
||||
.paletteTag = ANIM_TAG_IVY_CUDGEL_WATER,
|
||||
.oam = &gOamData_AffineDouble_ObjNormal_64x64,
|
||||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gWoodHammerHammerAffineAnims,
|
||||
.callback = AnimWoodHammerHammer,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gJudgmentGrayOutwardSpikesTemplate =
|
||||
{
|
||||
.tileTag = ANIM_TAG_GREEN_SPIKE,
|
||||
|
|
|
@ -6358,23 +6358,41 @@ bool32 IsNeutralizingGasOnField(void)
|
|||
return FALSE;
|
||||
}
|
||||
|
||||
bool32 IsMoldBreakerTypeAbility(u32 ability)
|
||||
bool32 IsMoldBreakerTypeAbility(u32 battler, u32 ability)
|
||||
{
|
||||
if (gStatuses3[battler] & STATUS3_GASTRO_ACID)
|
||||
return FALSE;
|
||||
|
||||
return (ability == ABILITY_MOLD_BREAKER || ability == ABILITY_TERAVOLT || ability == ABILITY_TURBOBLAZE
|
||||
|| (ability == ABILITY_MYCELIUM_MIGHT && IS_MOVE_STATUS(gCurrentMove)));
|
||||
}
|
||||
|
||||
static inline bool32 CanBreakThroughAbility(u32 battlerAtk, u32 battlerDef, u32 ability)
|
||||
{
|
||||
return ((IsMoldBreakerTypeAbility(battlerAtk, ability) || gMovesInfo[gCurrentMove].ignoresTargetAbility)
|
||||
&& battlerDef != battlerAtk
|
||||
&& gAbilitiesInfo[gBattleMons[battlerDef].ability].breakable
|
||||
&& gBattlerByTurnOrder[gCurrentTurnActionNumber] == battlerAtk
|
||||
&& gActionsByTurnOrder[gCurrentTurnActionNumber] == B_ACTION_USE_MOVE
|
||||
&& gCurrentTurnActionNumber < gBattlersCount);
|
||||
}
|
||||
|
||||
u32 GetBattlerAbility(u32 battler)
|
||||
{
|
||||
bool32 noAbilityShield = GetBattlerHoldEffectIgnoreAbility(battler, TRUE) != HOLD_EFFECT_ABILITY_SHIELD;
|
||||
bool32 abilityCantBeSuppressed = gAbilitiesInfo[gBattleMons[battler].ability].cantBeSuppressed;
|
||||
|
||||
if (gAbilitiesInfo[gBattleMons[battler].ability].cantBeSuppressed)
|
||||
if (abilityCantBeSuppressed)
|
||||
{
|
||||
// Edge case: pokemon under the effect of gastro acid transforms into a pokemon with Comatose (Todo: verify how other unsuppressable abilities behave)
|
||||
if (gBattleMons[battler].status2 & STATUS2_TRANSFORMED
|
||||
&& gStatuses3[battler] & STATUS3_GASTRO_ACID
|
||||
&& gBattleMons[battler].ability == ABILITY_COMATOSE)
|
||||
return ABILITY_NONE;
|
||||
|
||||
if (noAbilityShield && CanBreakThroughAbility(gBattlerAttacker, battler, gBattleMons[gBattlerAttacker].ability))
|
||||
return ABILITY_NONE;
|
||||
|
||||
return gBattleMons[battler].ability;
|
||||
}
|
||||
|
||||
|
@ -6386,15 +6404,7 @@ u32 GetBattlerAbility(u32 battler)
|
|||
&& noAbilityShield)
|
||||
return ABILITY_NONE;
|
||||
|
||||
if (((IsMoldBreakerTypeAbility(gBattleMons[gBattlerAttacker].ability)
|
||||
&& !(gStatuses3[gBattlerAttacker] & STATUS3_GASTRO_ACID))
|
||||
|| gMovesInfo[gCurrentMove].ignoresTargetAbility)
|
||||
&& battler != gBattlerAttacker
|
||||
&& gAbilitiesInfo[gBattleMons[battler].ability].breakable
|
||||
&& noAbilityShield
|
||||
&& gBattlerByTurnOrder[gCurrentTurnActionNumber] == gBattlerAttacker
|
||||
&& gActionsByTurnOrder[gCurrentTurnActionNumber] == B_ACTION_USE_MOVE
|
||||
&& gCurrentTurnActionNumber < gBattlersCount)
|
||||
if (noAbilityShield && CanBreakThroughAbility(gBattlerAttacker, battler, gBattleMons[gBattlerAttacker].ability))
|
||||
return ABILITY_NONE;
|
||||
|
||||
return gBattleMons[battler].ability;
|
||||
|
|
|
@ -1454,6 +1454,7 @@ const struct CompressedSpriteSheet gBattleAnimPicTable[] =
|
|||
{gBattleAnimSpriteGfx_SyrupShell, 0x2000, ANIM_TAG_SYRUP_SHELL_YELLOW},
|
||||
{gBattleAnimSpriteGfx_SyrupSplat, 0x400, ANIM_TAG_SYRUP_SPLAT_RED},
|
||||
{gBattleAnimSpriteGfx_SyrupSplat, 0x400, ANIM_TAG_SYRUP_SPLAT_YELLOW},
|
||||
{gBattleAnimSpriteGfx_IvyCudgel, 0x800, ANIM_TAG_IVY_CUDGEL_GRASS},
|
||||
{gBattleAnimSpriteGfx_TeraCrystal, 0x800, ANIM_TAG_TERA_CRYSTAL},
|
||||
{gBattleAnimSpriteGfx_TeraShatter, 0x0180, ANIM_TAG_TERA_SHATTER},
|
||||
{gBattleAnimSpriteGfx_DreepyMissile, 0x200, ANIM_TAG_DREEPY_SHINY},
|
||||
|
@ -1912,6 +1913,10 @@ const struct CompressedSpritePalette gBattleAnimPaletteTable[] =
|
|||
{gBattleAnimSpritePal_SyrupYellow, ANIM_TAG_SYRUP_SHELL_YELLOW},
|
||||
{gBattleAnimSpritePal_SyrupRed, ANIM_TAG_SYRUP_SPLAT_RED},
|
||||
{gBattleAnimSpritePal_SyrupYellow, ANIM_TAG_SYRUP_SPLAT_YELLOW},
|
||||
{gBattleAnimSpritePal_IvyCudgelGrass, ANIM_TAG_IVY_CUDGEL_GRASS},
|
||||
{gBattleAnimSpritePal_IvyCudgelFire, ANIM_TAG_IVY_CUDGEL_FIRE},
|
||||
{gBattleAnimSpritePal_IvyCudgelRock, ANIM_TAG_IVY_CUDGEL_ROCK},
|
||||
{gBattleAnimSpritePal_IvyCudgelWater, ANIM_TAG_IVY_CUDGEL_WATER},
|
||||
{gBattleAnimSpritePal_TeraCrystal, ANIM_TAG_TERA_CRYSTAL},
|
||||
{gBattleAnimSpritePal_TeraShatter, ANIM_TAG_TERA_SHATTER},
|
||||
{gBattleAnimSpritePal_DreepyMissileShiny, ANIM_TAG_DREEPY_SHINY},
|
||||
|
|
|
@ -771,7 +771,7 @@ void Snow_InitVars(void)
|
|||
gWeatherPtr->weatherGfxLoaded = FALSE;
|
||||
gWeatherPtr->targetColorMapIndex = 0;
|
||||
gWeatherPtr->colorMapStepDelay = 20;
|
||||
gWeatherPtr->targetSnowflakeSpriteCount = 16;
|
||||
gWeatherPtr->targetSnowflakeSpriteCount = NUM_SNOWFLAKE_SPRITES;
|
||||
gWeatherPtr->snowflakeVisibleCounter = 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -465,6 +465,12 @@ const u32 gBattleAnimSpriteGfx_SyrupSplat[] = INCBIN_U32("graphics/battle_anims/
|
|||
const u32 gBattleAnimSpritePal_SyrupRed[] = INCBIN_U32("graphics/battle_anims/sprites/syrup_red.gbapal.lz");
|
||||
const u32 gBattleAnimSpritePal_SyrupYellow[] = INCBIN_U32("graphics/battle_anims/sprites/syrup_yellow.gbapal.lz");
|
||||
|
||||
const u32 gBattleAnimSpriteGfx_IvyCudgel[] = INCBIN_U32("graphics/battle_anims/sprites/cudgel.4bpp.lz");
|
||||
const u32 gBattleAnimSpritePal_IvyCudgelGrass[] = INCBIN_U32("graphics/pokemon/ogerpon/normal.gbapal.lz");
|
||||
const u32 gBattleAnimSpritePal_IvyCudgelFire[] = INCBIN_U32("graphics/pokemon/ogerpon/hearthflame/normal.gbapal.lz");
|
||||
const u32 gBattleAnimSpritePal_IvyCudgelRock[] = INCBIN_U32("graphics/pokemon/ogerpon/cornerstone/normal.gbapal.lz");
|
||||
const u32 gBattleAnimSpritePal_IvyCudgelWater[] = INCBIN_U32("graphics/pokemon/ogerpon/wellspring/normal.gbapal.lz");
|
||||
|
||||
// old battle interface data, unused
|
||||
|
||||
const u32 gOldBattleInterfaceGfx[] = INCBIN_U32("graphics/unused/obi1.4bpp.lz");
|
||||
|
|
|
@ -121,3 +121,16 @@ SINGLE_BATTLE_TEST("Disguised Mimikyu takes damage from Rough Skin without break
|
|||
EXPECT_EQ(player->species, SPECIES_MIMIKYU_DISGUISED);
|
||||
}
|
||||
}
|
||||
|
||||
SINGLE_BATTLE_TEST("Disguised Mimikyu is ignored by Mold Breaker")
|
||||
{
|
||||
GIVEN {
|
||||
PLAYER(SPECIES_MIMIKYU_DISGUISED) { Ability(ABILITY_DISGUISE); }
|
||||
OPPONENT(SPECIES_PINSIR) { Ability(ABILITY_MOLD_BREAKER); }
|
||||
} WHEN {
|
||||
TURN { MOVE(opponent, MOVE_AERIAL_ACE); }
|
||||
} SCENE {
|
||||
ANIMATION(ANIM_TYPE_MOVE, MOVE_AERIAL_ACE, opponent);
|
||||
NOT ABILITY_POPUP(player, ABILITY_DISGUISE);
|
||||
}
|
||||
}
|
||||
|
|