summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPikalaxALT <pikalaxalt@gmail.com>2017-06-26 08:37:30 -0400
committerPikalaxALT <pikalaxalt@gmail.com>2017-06-26 08:37:30 -0400
commit155007d14989b2a798a15c6be8a00bb926d2c9b7 (patch)
tree8985029a2c55e6c5b83998c4c517c434f42755c0 /src
parentd7ab13d3a9b969b0267786e566595689338ae7c4 (diff)
sub_80697C8
Diffstat (limited to 'src')
-rwxr-xr-xsrc/field_tasks.c34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/field_tasks.c b/src/field_tasks.c
index 6682d01c3..34cbc9796 100755
--- a/src/field_tasks.c
+++ b/src/field_tasks.c
@@ -317,3 +317,37 @@ bool8 sub_806972C(s16 x1, s16 y1, s16 x2, s16 y2)
}
return TRUE;
}
+
+bool8 sub_80697C8(s16 x1, s16 y1, s16 x2, s16 y2)
+{
+ s8 metatileBehavior = MapGridGetMetatileBehaviorAt(x1, y1);
+ if (sub_80576A0(metatileBehavior))
+ {
+ if (y1 < y2)
+ {
+ return FALSE;
+ }
+ }
+ else if (sub_80576B4(metatileBehavior))
+ {
+ if (y1 > y2)
+ {
+ return FALSE;
+ }
+ }
+ else if (sub_80576C8(metatileBehavior))
+ {
+ if (x1 < x2)
+ {
+ return FALSE;
+ }
+ }
+ else if (sub_80576DC(metatileBehavior))
+ {
+ if (x1 > x2)
+ {
+ return FALSE;
+ }
+ }
+ return TRUE;
+}