From 7ec7ad36d5c1b00a266320a99de993b9d0c68b7d Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Fri, 23 May 2025 15:22:36 +0200 Subject: [PATCH] Move static inline to ground script.h --- include/ground_event.h | 18 ------------------ include/ground_script.h | 18 ++++++++++++++++++ 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/include/ground_event.h b/include/ground_event.h index 789713b57..84b2347be 100644 --- a/include/ground_event.h +++ b/include/ground_event.h @@ -3,24 +3,6 @@ #include "structs/str_position.h" -static inline void SetUnkInGroundEvent(const CompactPos *posPtr, PixelPos *dst) -{ - if (!(posPtr->xFlags & 4)) { - s32 x = posPtr->xTiles << 11; - dst->x = x; - if (posPtr->xFlags & 2) { - dst->x += 0x400; - } - } - if (!(posPtr->yFlags & 4)) { - s32 y = posPtr->yTiles << 11; - dst->y = y; - if (posPtr->yFlags & 2) { - dst->y += 0x400; - } - } -} - s16 FindGroundEvent(u32 flags, PixelPos *arg1, PixelPos *arg2); #endif // GUARD_GROUND_EVENT_H diff --git a/include/ground_script.h b/include/ground_script.h index e4077a5cb..03ac2c2c5 100644 --- a/include/ground_script.h +++ b/include/ground_script.h @@ -201,6 +201,24 @@ struct GroundScriptHeader { const struct GroundLink *links; }; +static inline void SetUnkInGroundEvent(const CompactPos *posPtr, PixelPos *dst) +{ + if (!(posPtr->xFlags & 4)) { + s32 x = posPtr->xTiles << 11; + dst->x = x; + if (posPtr->xFlags & 2) { + dst->x += 0x400; + } + } + if (!(posPtr->yFlags & 4)) { + s32 y = posPtr->yTiles << 11; + dst->y = y; + if (posPtr->yFlags & 2) { + dst->y += 0x400; + } + } +} + #include "debug.h" void InitScriptData(ScriptData *a0);