summaryrefslogtreecommitdiff
path: root/src/contest.c
diff options
context:
space:
mode:
authorCameron Hall <camthesaxman@users.noreply.github.com>2018-01-14 14:04:11 -0600
committerGitHub <noreply@github.com>2018-01-14 14:04:11 -0600
commit408c6ceddcc54a3aa45cdbb2923dc443d2e6297f (patch)
tree13fe61afef2608d6c9a595eb68396d62606f0b6a /src/contest.c
parent3e2f01c1eab4414f1c09844d19ae42535b8c4c4b (diff)
parenta5403f03dd49711f8c2f719e8bfa8a83f427563c (diff)
Merge pull request #526 from ProjectRevoTPP/contest_ai
decompile contest_ai.c
Diffstat (limited to 'src/contest.c')
-rw-r--r--src/contest.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/contest.c b/src/contest.c
index 875fe4502..df4bb361d 100644
--- a/src/contest.c
+++ b/src/contest.c
@@ -31,13 +31,12 @@
#include "tv.h"
#include "scanline_effect.h"
#include "util.h"
+#include "contest_ai.h"
extern u8 AreMovesContestCombo(u16, u16); // I don't think this is a bool
extern void sub_80C8A38(u8);
extern void sub_80C8AD0(u8);
extern void sub_80C8C80(u8);
-extern void sub_81288F4();
-extern u8 sub_8128944(void);
extern struct MusicPlayerInfo gMPlay_SE1;
extern u16 gSpecialVar_ContestCategory;
@@ -391,7 +390,7 @@ void ClearContestVars(void)
}
memset(&shared192D0, 0, sizeof(shared192D0));
- memset(shared192E4, 0, 0x44 * sizeof(*shared192E4));
+ memset(eContestAI, 0, sizeof(struct ContestAIInfo));
memset(&shared19328, 0, sizeof(shared19328));
memset(shared19338, 0, 4 * sizeof(*shared19338));
if (!(gIsLinkContest & 1))
@@ -2629,8 +2628,8 @@ u16 GetChosenMove(u8 a)
{
u8 moveChoice;
- sub_81288F4(a);
- moveChoice = sub_8128944();
+ ContestAI_ResetAI(a);
+ moveChoice = ContestAI_GetActionToUse();
return gContestMons[a].moves[moveChoice];
}
}