summaryrefslogtreecommitdiff
path: root/src/battle_ai_script_commands.c
diff options
context:
space:
mode:
authorPikalaxALT <pikalaxalt@gmail.com>2019-07-23 15:48:11 -0400
committerPikalaxALT <pikalaxalt@gmail.com>2019-07-23 15:48:11 -0400
commit0352a72d2ef5f820d6e8c4ad1806f5a8128b6d2f (patch)
tree1cda7283e7e7ac4678a14843a30d2519a37d3b34 /src/battle_ai_script_commands.c
parente3993e2b34282933f149b85a4cfe7f45e051b504 (diff)
parente4acfdf20b7d56b83cee6f4e49b257a2ecb92a95 (diff)
Merge branch 'master' of github.com:pret/pokefirered
Diffstat (limited to 'src/battle_ai_script_commands.c')
-rw-r--r--src/battle_ai_script_commands.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/battle_ai_script_commands.c b/src/battle_ai_script_commands.c
index ff3d26b65..1650f1056 100644
--- a/src/battle_ai_script_commands.c
+++ b/src/battle_ai_script_commands.c
@@ -1170,28 +1170,28 @@ static void BattleAICmd_get_ability(void)
return;
}
- if (gBaseStats[gBattleMons[index].species].ability1 != ABILITY_NONE)
+ if (gBaseStats[gBattleMons[index].species].abilities[0] != ABILITY_NONE)
{
- if (gBaseStats[gBattleMons[index].species].ability2 != ABILITY_NONE)
+ if (gBaseStats[gBattleMons[index].species].abilities[1] != ABILITY_NONE)
{
// AI has no knowledge of opponent, so it guesses which ability.
if (Random() % 2)
{
- AI_THINKING_STRUCT->funcResult = gBaseStats[gBattleMons[index].species].ability1;
+ AI_THINKING_STRUCT->funcResult = gBaseStats[gBattleMons[index].species].abilities[0];
}
else
{
- AI_THINKING_STRUCT->funcResult = gBaseStats[gBattleMons[index].species].ability2;
+ AI_THINKING_STRUCT->funcResult = gBaseStats[gBattleMons[index].species].abilities[1];
}
}
else
{
- AI_THINKING_STRUCT->funcResult = gBaseStats[gBattleMons[index].species].ability1; // it's definitely ability 1.
+ AI_THINKING_STRUCT->funcResult = gBaseStats[gBattleMons[index].species].abilities[0]; // it's definitely ability 1.
}
}
else
{
- AI_THINKING_STRUCT->funcResult = gBaseStats[gBattleMons[index].species].ability2; // AI cant actually reach this part since every mon has at least 1 ability.
+ AI_THINKING_STRUCT->funcResult = gBaseStats[gBattleMons[index].species].abilities[1]; // AI cant actually reach this part since every mon has at least 1 ability.
}
}
else