summaryrefslogtreecommitdiff
path: root/src/status_checker_1.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/status_checker_1.c')
-rw-r--r--src/status_checker_1.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/status_checker_1.c b/src/status_checker_1.c
new file mode 100644
index 0000000..ebe6db6
--- /dev/null
+++ b/src/status_checker_1.c
@@ -0,0 +1,21 @@
+#include "global.h"
+#include "status_checker_1.h"
+
+#include "dungeon_entity.h"
+
+bool8 HasLastUsedMove(struct PokemonMove *moves)
+{
+ s32 i;
+ for (i = 0; i < MAX_MON_MOVES; i++)
+ {
+ if (moves[i].moveFlags & MOVE_FLAG_EXISTS && moves[i].moveFlags & MOVE_FLAG_LAST_USED)
+ {
+ return TRUE;
+ }
+ }
+ if (moves[STRUGGLE_MOVE_INDEX].moveFlags & MOVE_FLAG_LAST_USED)
+ {
+ return TRUE;
+ }
+ return FALSE;
+}