merge targeting with code_805D8C8

This commit is contained in:
DizzyEggg
2025-03-16 17:10:01 +01:00
parent de44401997
commit c63ae1297f
3 changed files with 8 additions and 12 deletions

View File

@@ -234,7 +234,6 @@ SECTIONS {
src/dungeon_menu_recruitment.o(.text);
src/code_8066D04.o(.text);
src/code_805D8C8.o(.text);
src/targeting.o(.text);
src/code_8069E0C.o(.text);
src/code_806CD90.o(.text);
src/type_effectiveness.o(.text);

View File

@@ -1050,3 +1050,11 @@ void sub_8069D4C(struct unkStruct_8069D4C *r0, Entity *target)
r0->maxBelly = info->maxBelly;
r0->hiddenPower = info->hiddenPower;
}
void TargetTileInFront(Entity *pokemon)
{
EntityInfo *pokemonInfo = GetEntInfo(pokemon);
pokemonInfo->targetPos.x = pokemon->pos.x + gAdjacentTileOffsets[pokemonInfo->action.direction].x;
pokemonInfo->targetPos.y = pokemon->pos.y + gAdjacentTileOffsets[pokemonInfo->action.direction].y;
}

View File

@@ -1,11 +0,0 @@
#include "global.h"
#include "targeting.h"
#include "dungeon_util.h"
void TargetTileInFront(Entity *pokemon)
{
EntityInfo *pokemonInfo = GetEntInfo(pokemon);
pokemonInfo->targetPos.x = pokemon->pos.x + gAdjacentTileOffsets[pokemonInfo->action.direction].x;
pokemonInfo->targetPos.y = pokemon->pos.y + gAdjacentTileOffsets[pokemonInfo->action.direction].y;
}