diff options
Diffstat (limited to 'src/berry_tag_screen.c')
-rw-r--r-- | src/berry_tag_screen.c | 27 |
1 files changed, 24 insertions, 3 deletions
diff --git a/src/berry_tag_screen.c b/src/berry_tag_screen.c index f0bcb4f27..116ca2cca 100644 --- a/src/berry_tag_screen.c +++ b/src/berry_tag_screen.c @@ -1,11 +1,13 @@ #include "global.h" #include "berry_tag_screen.h" -#include "asm.h" #include "berry.h" #include "decompress.h" +#include "field_map_obj.h" +#include "item_menu.h" #include "items.h" #include "main.h" #include "menu.h" +#include "menu_helpers.h" #include "palette.h" #include "rom4.h" #include "songs.h" @@ -36,8 +38,8 @@ extern struct BerryTagStatus gUnknown_0203932E; extern u16 gScriptItemId; extern u16 gUnknown_030041B4; -extern const struct SpriteSheet gUnknown_083C1F74; -extern const struct SpritePalette gUnknown_083C1F7C; +extern const struct CompressedSpriteSheet gUnknown_083C1F74; +extern const struct CompressedSpritePalette gUnknown_083C1F7C; extern u8 *gUnknown_0841192C[]; @@ -263,30 +265,49 @@ static void sub_8146480(u8 taskid) static void sub_81464E4(void) { const struct Berry *berryInfo; +#ifdef UNITS_IMPERIAL u32 size; s32 sizeMajor; s32 sizeMinor; +#endif +#if GERMAN + u8 buffer[16]; +#endif berryInfo = GetBerryInfo(gScriptItemId + OFFSET_7B + 1); ConvertIntToDecimalStringN(gStringVar1, gScriptItemId - FIRST_BERRY + 1, STR_CONV_MODE_LEADING_ZEROS, 2); MenuPrint(gStringVar1, 12, 4); +#if ENGLISH MenuPrint(berryInfo->name, 14, 4); +#elif GERMAN + StringCopy(buffer, berryInfo->name); + StringAppend(buffer, gOtherText_Berry2); + MenuPrint(buffer, 14, 4); +#endif + MenuPrint(berryInfo->description1, 4, 14); MenuPrint(berryInfo->description2, 4, 16); +#ifdef UNITS_IMPERIAL size = (berryInfo->size * 1000) / 254; if (size % 10 >= 5) size += 10; sizeMinor = (size % 100) / 10; sizeMajor = size / 100; +#endif MenuPrint(gOtherText_Size, 11, 7); if (berryInfo->size != 0) { +#ifdef UNITS_IMPERIAL ConvertIntToDecimalStringN(gStringVar1, sizeMajor, STR_CONV_MODE_LEFT_ALIGN, 2); ConvertIntToDecimalStringN(gStringVar2, sizeMinor, STR_CONV_MODE_LEFT_ALIGN, 2); +#else + ConvertIntToDecimalStringN(gStringVar1, berryInfo->size / 10, STR_CONV_MODE_LEFT_ALIGN, 2); + ConvertIntToDecimalStringN(gStringVar2, berryInfo->size % 10, STR_CONV_MODE_LEFT_ALIGN, 2); +#endif MenuPrint(gContestStatsText_Unknown1, 16, 7); } else |