mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-26 11:44:17 +01:00
Document some of trade
This commit is contained in:
parent
c3c8fb40cf
commit
4a7f061885
13
gflib/text.h
13
gflib/text.h
@ -107,12 +107,19 @@
|
|||||||
#define TEXT_COLOR_TRANSPARENT 0x0
|
#define TEXT_COLOR_TRANSPARENT 0x0
|
||||||
#define TEXT_COLOR_WHITE 0x1
|
#define TEXT_COLOR_WHITE 0x1
|
||||||
#define TEXT_COLOR_DARK_GREY 0x2
|
#define TEXT_COLOR_DARK_GREY 0x2
|
||||||
// 0x3
|
#define TEXT_COLOR_LIGHT_GREY 0x3
|
||||||
#define TEXT_COLOR_RED 0x4
|
#define TEXT_COLOR_RED 0x4
|
||||||
// 0x5
|
#define TEXT_COLOR_LIGHT_RED 0x5
|
||||||
#define TEXT_COLOR_GREEN 0x6
|
#define TEXT_COLOR_GREEN 0x6
|
||||||
// 0x7
|
#define TEXT_COLOR_LIGHT_GREEN 0x7
|
||||||
#define TEXT_COLOR_BLUE 0x8
|
#define TEXT_COLOR_BLUE 0x8
|
||||||
|
#define TEXT_COLOR_LIGHT_BLUE 0x9
|
||||||
|
#define TEXT_DYNAMIC_COLOR_1 0xA // Usually white
|
||||||
|
#define TEXT_DYNAMIC_COLOR_2 0xB // Usually white w/ tinge of green
|
||||||
|
#define TEXT_DYNAMIC_COLOR_3 0xC // Usually white
|
||||||
|
#define TEXT_DYNAMIC_COLOR_4 0xD // Usually aquamarine
|
||||||
|
#define TEXT_DYNAMIC_COLOR_5 0xE // Usually blue-green
|
||||||
|
#define TEXT_DYNAMIC_COLOR_6 0xF // Usually cerulean
|
||||||
|
|
||||||
#define PLACEHOLDER_ID_UNKNOWN 0x0
|
#define PLACEHOLDER_ID_UNKNOWN 0x0
|
||||||
#define PLACEHOLDER_ID_PLAYER 0x1
|
#define PLACEHOLDER_ID_PLAYER 0x1
|
||||||
|
@ -3,11 +3,40 @@
|
|||||||
|
|
||||||
#define TRADE_PLAYER 0
|
#define TRADE_PLAYER 0
|
||||||
#define TRADE_PARTNER 1
|
#define TRADE_PARTNER 1
|
||||||
#define TRADE_PARTICIPANT_COUNT 2
|
|
||||||
|
|
||||||
#define INGAME_TRADE_SEEDOT 0
|
#define INGAME_TRADE_SEEDOT 0
|
||||||
#define INGAME_TRADE_PLUSLE 1
|
#define INGAME_TRADE_PLUSLE 1
|
||||||
#define INGAME_TRADE_HORSEA 2
|
#define INGAME_TRADE_HORSEA 2
|
||||||
#define INGAME_TRADE_MEOWTH 3
|
#define INGAME_TRADE_MEOWTH 3
|
||||||
|
|
||||||
|
#define INGAME_TRADE_MAIL_LENGTH 9
|
||||||
|
|
||||||
|
#define PLAYER_MON_INVALID 0
|
||||||
|
#define PLAYER_MON_VALID 1
|
||||||
|
#define PARTNER_MON_INVALID 2
|
||||||
|
|
||||||
|
#define MON_VALID 0
|
||||||
|
|
||||||
|
|
||||||
|
#define TRADE_ACTION_TEXT_CANCEL 0
|
||||||
|
#define TRADE_ACTION_TEXT_CHOOSE_MON 1
|
||||||
|
#define TRADE_ACTION_TEXT_SUMMARY 2
|
||||||
|
#define TRADE_ACTION_TEXT_TRADE 3
|
||||||
|
#define TRADE_ACTION_TEXT_CANCEL_TRADE 4
|
||||||
|
#define TRADE_ACTION_TEXT_JP_QUIT 5
|
||||||
|
|
||||||
|
#define MENU_ACTION_SUMMARY 0
|
||||||
|
#define MENU_ACTION_TRADE 1
|
||||||
|
|
||||||
|
#define TRADE_MSG_STANDBY 0
|
||||||
|
#define TRADE_MSG_CANCELED 1
|
||||||
|
#define TRADE_MSG_ONLY_MON1 2
|
||||||
|
#define TRADE_MSG_ONLY_MON2 3
|
||||||
|
#define TRADE_MSG_WAITING_FOR_FRIEND 4
|
||||||
|
#define TRADE_MSG_FRIEND_WANTS_TO_TRADE 5
|
||||||
|
#define TRADE_MSG_MON_CANT_BE_TRADED 6
|
||||||
|
#define TRADE_MSG_EGG_CANT_BE_TRADED 7
|
||||||
|
#define TRADE_MSG_FRIENDS_MON_CANT_BE_TRADED 8
|
||||||
|
|
||||||
|
|
||||||
#endif //GUARD_CONSTANTS_TRADE_H
|
#endif //GUARD_CONSTANTS_TRADE_H
|
||||||
|
@ -22,7 +22,7 @@ u8 UpdateMonIconFrame(struct Sprite *sprite);
|
|||||||
void LoadMonIconPalette(u16 species);
|
void LoadMonIconPalette(u16 species);
|
||||||
void sub_80D328C(struct Sprite *sprite);
|
void sub_80D328C(struct Sprite *sprite);
|
||||||
void sub_80D3014(struct Sprite *sprite);
|
void sub_80D3014(struct Sprite *sprite);
|
||||||
void sub_80D32C8(struct Sprite *sprite, u8 animNum);
|
void SetPartyHPBarSprite(struct Sprite *sprite, u8 animNum);
|
||||||
u8 GetMonIconPaletteIndexFromSpecies(u16 species);
|
u8 GetMonIconPaletteIndexFromSpecies(u16 species);
|
||||||
|
|
||||||
#endif // GUARD_POKEMON_ICON_H
|
#endif // GUARD_POKEMON_ICON_H
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
#define GUARD_TRADE_H
|
#define GUARD_TRADE_H
|
||||||
|
|
||||||
#include "link_rfu.h"
|
#include "link_rfu.h"
|
||||||
|
#include "constants/trade.h"
|
||||||
|
|
||||||
// Exported type declarations
|
// Exported type declarations
|
||||||
|
|
||||||
@ -21,6 +22,6 @@ int sub_807A918(struct Pokemon*, u16);
|
|||||||
void sub_807B140(void);
|
void sub_807B140(void);
|
||||||
void sub_807B154(void);
|
void sub_807B154(void);
|
||||||
void sub_807F19C(void);
|
void sub_807F19C(void);
|
||||||
void sub_807F1A8(u8, const u8 *, u8);
|
void DrawTextOnTradeWindow(u8, const u8 *, u8);
|
||||||
|
|
||||||
#endif //GUARD_TRADE_H
|
#endif //GUARD_TRADE_H
|
||||||
|
@ -1084,8 +1084,8 @@ static void sub_80B37FC(u8 taskId)
|
|||||||
task->data[0]++;
|
task->data[0]++;
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
gSelectedTradeMonPositions[0] = 0;
|
gSelectedTradeMonPositions[TRADE_PLAYER] = 0;
|
||||||
gSelectedTradeMonPositions[1] = 0;
|
gSelectedTradeMonPositions[TRADE_PARTNER] = 0;
|
||||||
m4aMPlayAllStop();
|
m4aMPlayAllStop();
|
||||||
sub_800AC34();
|
sub_800AC34();
|
||||||
task->data[0]++;
|
task->data[0]++;
|
||||||
@ -1117,8 +1117,8 @@ static void sub_80B3894(u8 taskId)
|
|||||||
data[0]++;
|
data[0]++;
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
gSelectedTradeMonPositions[0] = 0;
|
gSelectedTradeMonPositions[TRADE_PLAYER] = 0;
|
||||||
gSelectedTradeMonPositions[1] = 0;
|
gSelectedTradeMonPositions[TRADE_PARTNER] = 0;
|
||||||
m4aMPlayAllStop();
|
m4aMPlayAllStop();
|
||||||
sub_800ADF8();
|
sub_800ADF8();
|
||||||
data[0]++;
|
data[0]++;
|
||||||
|
133
src/data/trade.h
133
src/data/trade.h
@ -7,6 +7,7 @@ static const u32 sUnref_0832C6A8[] =
|
|||||||
0x00000064,
|
0x00000064,
|
||||||
0x00000528
|
0x00000528
|
||||||
};
|
};
|
||||||
|
|
||||||
static const u16 gTradeMovesBoxTilemap[] = INCBIN_U16("graphics/trade/moves_box_map.bin");
|
static const u16 gTradeMovesBoxTilemap[] = INCBIN_U16("graphics/trade/moves_box_map.bin");
|
||||||
static const u16 gTradePartyBoxTilemap[] = INCBIN_U16("graphics/trade/party_box_map.bin");
|
static const u16 gTradePartyBoxTilemap[] = INCBIN_U16("graphics/trade/party_box_map.bin");
|
||||||
static const u8 gTradeStripesBG2Tilemap[] = INCBIN_U8("graphics/trade/stripes_bg2_map.bin");
|
static const u8 gTradeStripesBG2Tilemap[] = INCBIN_U8("graphics/trade/stripes_bg2_map.bin");
|
||||||
@ -24,19 +25,19 @@ static const u8 gText_ThreeDashes2[] = _("---");
|
|||||||
static const u8 gText_FourQuestionMarks[] = _("????");
|
static const u8 gText_FourQuestionMarks[] = _("????");
|
||||||
static const u8 gText_832DAE4[] = _("");
|
static const u8 gText_832DAE4[] = _("");
|
||||||
static const u8 gText_IsThisTradeOkay[] = _("Is this trade okay?");
|
static const u8 gText_IsThisTradeOkay[] = _("Is this trade okay?");
|
||||||
static const u8 gText_Cancel6[] = _("CANCEL");
|
static const u8 sText_Cancel[] = _("CANCEL");
|
||||||
static const u8 gText_ChooseAPkmn[] = _("Choose a POKéMON.");
|
static const u8 sText_ChooseAPkmn[] = _("Choose a POKéMON.");
|
||||||
static const u8 gText_Summary3[] = _("SUMMARY");
|
static const u8 sText_Summary[] = _("SUMMARY");
|
||||||
static const u8 gText_Trade2[] = _("TRADE");
|
static const u8 sText_Trade[] = _("TRADE");
|
||||||
static const u8 gText_CancelTrade[] = _("Cancel trade?");
|
static const u8 sText_CancelTrade[] = _("Cancel trade?");
|
||||||
static const u8 gJPText_832DB2E[] = _("Bボタン で もどります");
|
static const u8 sJPText_PressBButtonToQuit[] = _("Bボタン で もどります");
|
||||||
static const u8 gText_Summary4[] = _("SUMMARY");
|
static const u8 sText_Summary2[] = _("SUMMARY");
|
||||||
static const u8 gText_Trade3[] = _("TRADE");
|
static const u8 sText_Trade2[] = _("TRADE");
|
||||||
static const u8 gText_CommunicationStandby6[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}Communication standby…\nPlease wait.");
|
static const u8 sText_CommunicationStandby[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}Communication standby…\nPlease wait.");
|
||||||
static const u8 gText_TheTradeHasBeenCanceled[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}The trade has\nbeen canceled.");
|
static const u8 sText_TheTradeHasBeenCanceled[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}The trade has\nbeen canceled.");
|
||||||
static const u8 gText_YourOnlyPkmnForBattle[] = _("That's your only\nPOKéMON for battle.");
|
static const u8 sText_OnlyPkmnForBattle[] = _("That's your only\nPOKéMON for battle.");
|
||||||
static const u8 gText_WaitingForYourFriend[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}Waiting for your friend\nto finish…");
|
static const u8 sText_WaitingForYourFriend[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}Waiting for your friend\nto finish…");
|
||||||
static const u8 gText_YourFriendWantsToTrade[] = _("Your friend wants\nto trade POKéMON.");
|
static const u8 sText_YourFriendWantsToTrade[] = _("Your friend wants\nto trade POKéMON.");
|
||||||
|
|
||||||
static const struct OamData gOamData_832DC14 =
|
static const struct OamData gOamData_832DC14 =
|
||||||
{
|
{
|
||||||
@ -336,35 +337,41 @@ static const u8 sUnref_0832DE6E[] =
|
|||||||
0x17, 0x0c
|
0x17, 0x0c
|
||||||
};
|
};
|
||||||
|
|
||||||
static const u8 *const gUnknown_0832DE94[] =
|
static const u8 *const sTradeActionTexts[] =
|
||||||
{
|
{
|
||||||
gText_Cancel6,
|
[TRADE_ACTION_TEXT_CANCEL] = sText_Cancel,
|
||||||
gText_ChooseAPkmn,
|
[TRADE_ACTION_TEXT_CHOOSE_MON] = sText_ChooseAPkmn,
|
||||||
gText_Summary3,
|
[TRADE_ACTION_TEXT_SUMMARY] = sText_Summary,
|
||||||
gText_Trade2,
|
[TRADE_ACTION_TEXT_TRADE] = sText_Trade,
|
||||||
gText_CancelTrade,
|
[TRADE_ACTION_TEXT_CANCEL_TRADE] = sText_CancelTrade,
|
||||||
gJPText_832DB2E
|
[TRADE_ACTION_TEXT_JP_QUIT] = sJPText_PressBButtonToQuit
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct MenuAction gUnknown_0832DEAC[] =
|
static const struct MenuAction sSelectTradeMonActions[] =
|
||||||
{
|
{
|
||||||
{gText_Summary4, sub_807A000},
|
[MENU_ACTION_SUMMARY] = {sText_Summary2, sub_807A000},
|
||||||
{gText_Trade3, sub_807A024}
|
[MENU_ACTION_TRADE] = {sText_Trade2, sub_807A024}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const u8 *const gUnknown_0832DEBC[] = {
|
static const u8 *const sTradeMessageTexts[] =
|
||||||
gText_CommunicationStandby6,
|
{
|
||||||
gText_TheTradeHasBeenCanceled,
|
[TRADE_MSG_STANDBY] = sText_CommunicationStandby,
|
||||||
gText_YourOnlyPkmnForBattle,
|
[TRADE_MSG_CANCELED] = sText_TheTradeHasBeenCanceled,
|
||||||
gText_OnlyPkmnForBattle,
|
[TRADE_MSG_ONLY_MON1] = sText_OnlyPkmnForBattle,
|
||||||
gText_WaitingForYourFriend,
|
[TRADE_MSG_ONLY_MON2] = gText_OnlyPkmnForBattle, //identical text to above
|
||||||
gText_YourFriendWantsToTrade,
|
[TRADE_MSG_WAITING_FOR_FRIEND] = sText_WaitingForYourFriend,
|
||||||
gText_PkmnCantBeTradedNow,
|
[TRADE_MSG_FRIEND_WANTS_TO_TRADE] = sText_YourFriendWantsToTrade,
|
||||||
gText_EggCantBeTradedNow,
|
[TRADE_MSG_MON_CANT_BE_TRADED] = gText_PkmnCantBeTradedNow,
|
||||||
gText_OtherTrainersPkmnCantBeTraded
|
[TRADE_MSG_EGG_CANT_BE_TRADED] = gText_EggCantBeTradedNow,
|
||||||
|
[TRADE_MSG_FRIENDS_MON_CANT_BE_TRADED] = gText_OtherTrainersPkmnCantBeTraded
|
||||||
};
|
};
|
||||||
|
|
||||||
static const u8 gUnknown_0832DEE0[] = { 0, 1, 2 };
|
static const u8 sTradeTextColors[] =
|
||||||
|
{
|
||||||
|
TEXT_COLOR_TRANSPARENT, //bg color
|
||||||
|
TEXT_COLOR_WHITE, //fg color
|
||||||
|
TEXT_COLOR_DARK_GREY //shadow color
|
||||||
|
};
|
||||||
|
|
||||||
static const struct BgTemplate gUnknown_0832DEE4[] =
|
static const struct BgTemplate gUnknown_0832DEE4[] =
|
||||||
{
|
{
|
||||||
@ -573,7 +580,7 @@ static const struct WindowTemplate gUnknown_0832DEF4[] =
|
|||||||
DUMMY_WIN_TEMPLATE,
|
DUMMY_WIN_TEMPLATE,
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct WindowTemplate gUnknown_0832DF8C =
|
static const struct WindowTemplate sTradeYesNoWindowTemplate =
|
||||||
{
|
{
|
||||||
.bg = 0,
|
.bg = 0,
|
||||||
.tilemapLeft = 23,
|
.tilemapLeft = 23,
|
||||||
@ -584,7 +591,7 @@ static const struct WindowTemplate gUnknown_0832DF8C =
|
|||||||
.baseBlock = 582
|
.baseBlock = 582
|
||||||
};
|
};
|
||||||
|
|
||||||
static const u8 gJPText_Shedinja[] = _("ヌケニン");
|
static const u8 sJPText_Shedinja[] = _("ヌケニン");
|
||||||
static const u8 gUnknown_0832DF99[][2] =
|
static const u8 gUnknown_0832DF99[][2] =
|
||||||
{
|
{
|
||||||
{4, 3},
|
{4, 3},
|
||||||
@ -592,20 +599,20 @@ static const u8 gUnknown_0832DF99[][2] =
|
|||||||
{0, 0}
|
{0, 0}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const u16 gTradeBallPalette[] = INCBIN_U16("graphics/trade/ball.gbapal");
|
static const u16 sTradePal_Ball[] = INCBIN_U16("graphics/trade/ball.gbapal");
|
||||||
static const u8 gTradeBallTiles[] = INCBIN_U8("graphics/trade/ball.4bpp");
|
static const u8 sTradeGfx_Ball[] = INCBIN_U8("graphics/trade/ball.4bpp");
|
||||||
static const u8 gUnknown_832E5C0[] = INCBIN_U8("graphics/trade/pokeball_symbol.8bpp");
|
static const u8 sTradeGfx_PokeBallSymbol[] = INCBIN_U8("graphics/trade/pokeball_symbol.8bpp"); // unused?
|
||||||
static const u16 gUnknown_0832FFC0[] = INCBIN_U16("graphics/trade/cable_closeup_map.bin");
|
static const u16 sTradeTilemap_Cable[] = INCBIN_U16("graphics/trade/cable_closeup_map.bin");
|
||||||
static const u16 gUnknown_083307C0[] = INCBIN_U16("graphics/trade/pokeball_symbol_map.bin");
|
static const u16 sTradeTilemap_PokeBallSymbol[] = INCBIN_U16("graphics/trade/pokeball_symbol_map.bin"); // unused?
|
||||||
static const u16 sUnref_083308C0[] = INCBIN_U16("graphics/trade/unknown_3308C0.gbapal");
|
static const u16 sUnref_083308C0[] = INCBIN_U16("graphics/trade/unknown_3308C0.gbapal");
|
||||||
static const u16 gUnknown_083308E0[] = INCBIN_U16("graphics/trade/gba.gbapal");
|
static const u16 sTradePal_Gba[] = INCBIN_U16("graphics/trade/gba.gbapal");
|
||||||
static const u16 gUnref_08330900[] = INCBIN_U16("graphics/trade/shadow.gbapal");
|
static const u16 sTradePal_ShadowUnused[] = INCBIN_U16("graphics/trade/shadow.gbapal");
|
||||||
static const u16 gUnref_08330920[] = INCBIN_U16("graphics/trade/black.gbapal");
|
static const u16 sTradePal_BlackUnused[] = INCBIN_U16("graphics/trade/black.gbapal");
|
||||||
static const u16 gUnknown_08330940[] = INCBIN_U16("graphics/trade/misc.gbapal");
|
static const u16 sTradePal_Misc[] = INCBIN_U16("graphics/trade/misc.gbapal");
|
||||||
static const u8 gTradeGlow1Tiles[] = INCBIN_U8("graphics/trade/glow1.4bpp");
|
static const u8 sTradeGfx_Glow1[] = INCBIN_U8("graphics/trade/glow1.4bpp");
|
||||||
static const u8 gTradeGlow2Tiles[] = INCBIN_U8("graphics/trade/glow2.4bpp");
|
static const u8 sTradeGfx_Glow2[] = INCBIN_U8("graphics/trade/glow2.4bpp");
|
||||||
static const u8 gTradeCableEndTiles[] = INCBIN_U8("graphics/trade/cable_end.4bpp");
|
static const u8 sTradeGfx_CableEnd[] = INCBIN_U8("graphics/trade/cable_end.4bpp");
|
||||||
static const u8 gTradeGBAScreenTiles[] = INCBIN_U8("graphics/trade/gba_screen.4bpp");
|
static const u8 sTradeGfx_GbaScreen[] = INCBIN_U8("graphics/trade/gba_screen.4bpp");
|
||||||
const u16 gUnknown_08331F60[] = INCBIN_U16("graphics/trade/shadow_map.bin");
|
const u16 gUnknown_08331F60[] = INCBIN_U16("graphics/trade/shadow_map.bin");
|
||||||
static const u8 gUnknown_08332F60[] = INCBIN_U8("graphics/trade/gba_affine.8bpp");
|
static const u8 gUnknown_08332F60[] = INCBIN_U8("graphics/trade/gba_affine.8bpp");
|
||||||
static const u8 sFiller_08335760[64] = {};
|
static const u8 sFiller_08335760[64] = {};
|
||||||
@ -614,11 +621,11 @@ static const u8 gUnknown_083358A0[] = INCBIN_U8("graphics/trade/gba_affine_map_w
|
|||||||
static const u16 gUnknown_083359A0[] = INCBIN_U16("graphics/trade/gba_map_wireless.bin");
|
static const u16 gUnknown_083359A0[] = INCBIN_U16("graphics/trade/gba_map_wireless.bin");
|
||||||
static const u16 gUnknown_083369A0[] = INCBIN_U16("graphics/trade/gba_map_cable.bin");
|
static const u16 gUnknown_083369A0[] = INCBIN_U16("graphics/trade/gba_map_cable.bin");
|
||||||
static const u32 gUnknown_083379A0[] = INCBIN_U32("graphics/trade/unknown_3379A0.bin.lz");
|
static const u32 gUnknown_083379A0[] = INCBIN_U32("graphics/trade/unknown_3379A0.bin.lz");
|
||||||
static const u16 gUnknown_08337AA0[] = INCBIN_U16("graphics/trade/wireless_signal_send.gbapal");
|
static const u16 sTradePal_WirelessSignalSend[] = INCBIN_U16("graphics/trade/wireless_signal_send.gbapal");
|
||||||
static const u16 gUnknown_08337CA0[] = INCBIN_U16("graphics/trade/wireless_signal_receive.gbapal");
|
static const u16 sTradePal_WirelessSignalReceive[] = INCBIN_U16("graphics/trade/wireless_signal_receive.gbapal");
|
||||||
static const u16 gUnknown_08337EA0[] = INCBIN_U16("graphics/trade/black.gbapal");
|
static const u16 sTradePal_Black[] = INCBIN_U16("graphics/trade/black.gbapal");
|
||||||
static const u32 gUnknown_08337EC0[] = INCBIN_U32("graphics/trade/wireless_signal.4bpp.lz");
|
static const u32 sTradeGfx_WirelessSignal[] = INCBIN_U32("graphics/trade/wireless_signal.4bpp.lz");
|
||||||
static const u32 gUnknown_08338550[] = INCBIN_U32("graphics/trade/wireless_signal.bin.lz");
|
static const u32 sTradeTilemap_WirelessSignal[] = INCBIN_U32("graphics/trade/wireless_signal.bin.lz");
|
||||||
|
|
||||||
static const struct OamData gOamData_8338C44 =
|
static const struct OamData gOamData_8338C44 =
|
||||||
{
|
{
|
||||||
@ -700,14 +707,14 @@ static const union AffineAnimCmd *const gSpriteAffineAnimTable_8338D0C[] =
|
|||||||
|
|
||||||
static const struct SpriteSheet gUnknown_08338D18 =
|
static const struct SpriteSheet gUnknown_08338D18 =
|
||||||
{
|
{
|
||||||
.data = gTradeBallTiles,
|
.data = sTradeGfx_Ball,
|
||||||
.size = 0x600,
|
.size = 0x600,
|
||||||
.tag = 5557
|
.tag = 5557
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct SpritePalette gUnknown_08338D20 =
|
static const struct SpritePalette gUnknown_08338D20 =
|
||||||
{
|
{
|
||||||
.data = gTradeBallPalette,
|
.data = sTradePal_Ball,
|
||||||
.tag = 5558
|
.tag = 5558
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -756,20 +763,20 @@ static const union AffineAnimCmd *const gSpriteAffineAnimTable_8338D6C[] =
|
|||||||
|
|
||||||
static const struct SpriteSheet gUnknown_08338D70 =
|
static const struct SpriteSheet gUnknown_08338D70 =
|
||||||
{
|
{
|
||||||
.data = gTradeGlow1Tiles,
|
.data = sTradeGfx_Glow1,
|
||||||
.size = 0x200,
|
.size = 0x200,
|
||||||
.tag = 5550
|
.tag = 5550
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct SpritePalette gUnknown_08338D78 =
|
static const struct SpritePalette gUnknown_08338D78 =
|
||||||
{
|
{
|
||||||
.data = gUnknown_08330940,
|
.data = sTradePal_Misc,
|
||||||
.tag = 5551
|
.tag = 5551
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct SpritePalette gUnknown_08338D80 =
|
static const struct SpritePalette gUnknown_08338D80 =
|
||||||
{
|
{
|
||||||
.data = gUnknown_083308E0,
|
.data = sTradePal_Gba,
|
||||||
.tag = 5555
|
.tag = 5555
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -811,7 +818,7 @@ static const union AnimCmd *const gSpriteAnimTable_8338DB8[] =
|
|||||||
|
|
||||||
static const struct SpriteSheet gUnknown_08338DC0 =
|
static const struct SpriteSheet gUnknown_08338DC0 =
|
||||||
{
|
{
|
||||||
.data = gTradeGlow2Tiles,
|
.data = sTradeGfx_Glow2,
|
||||||
.size = 0x300,
|
.size = 0x300,
|
||||||
.tag = 5552
|
.tag = 5552
|
||||||
};
|
};
|
||||||
@ -847,7 +854,7 @@ static const union AnimCmd *const gSpriteAnimTable_8338DF0[] =
|
|||||||
|
|
||||||
static const struct SpriteSheet gUnknown_08338DF4 =
|
static const struct SpriteSheet gUnknown_08338DF4 =
|
||||||
{
|
{
|
||||||
.data = gTradeCableEndTiles,
|
.data = sTradeGfx_CableEnd,
|
||||||
.size = 0x100,
|
.size = 0x100,
|
||||||
.tag = 5554
|
.tag = 5554
|
||||||
};
|
};
|
||||||
@ -908,7 +915,7 @@ static const union AnimCmd *const gSpriteAnimTable_8338E68[] =
|
|||||||
|
|
||||||
static const struct SpriteSheet gUnknown_08338E6C =
|
static const struct SpriteSheet gUnknown_08338E6C =
|
||||||
{
|
{
|
||||||
.data = gTradeGBAScreenTiles,
|
.data = sTradeGfx_GbaScreen,
|
||||||
.size = 0x1000,
|
.size = 0x1000,
|
||||||
.tag = 5556
|
.tag = 5556
|
||||||
};
|
};
|
||||||
@ -1016,7 +1023,7 @@ static const struct InGameTrade sIngameTrades[] =
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
static const u16 gIngameTradeMail[][10] =
|
static const u16 sIngameTradeMail[][INGAME_TRADE_MAIL_LENGTH + 1] =
|
||||||
{
|
{
|
||||||
{
|
{
|
||||||
EC_WORD_BE,
|
EC_WORD_BE,
|
||||||
|
@ -985,7 +985,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
StringExpandPlaceholders(gStringVar4, gText_PkmnIsEvolving);
|
StringExpandPlaceholders(gStringVar4, gText_PkmnIsEvolving);
|
||||||
sub_807F1A8(0, gStringVar4, 1);
|
DrawTextOnTradeWindow(0, gStringVar4, 1);
|
||||||
gTasks[taskID].tState++;
|
gTasks[taskID].tState++;
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
@ -1075,7 +1075,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
if (IsCryFinished())
|
if (IsCryFinished())
|
||||||
{
|
{
|
||||||
StringExpandPlaceholders(gStringVar4, gText_CongratsPkmnEvolved);
|
StringExpandPlaceholders(gStringVar4, gText_CongratsPkmnEvolved);
|
||||||
sub_807F1A8(0, gStringVar4, 1);
|
DrawTextOnTradeWindow(0, gStringVar4, 1);
|
||||||
PlayFanfare(MUS_FANFA5);
|
PlayFanfare(MUS_FANFA5);
|
||||||
gTasks[taskID].tState++;
|
gTasks[taskID].tState++;
|
||||||
SetMonData(mon, MON_DATA_SPECIES, (&gTasks[taskID].tPostEvoSpecies));
|
SetMonData(mon, MON_DATA_SPECIES, (&gTasks[taskID].tPostEvoSpecies));
|
||||||
@ -1110,7 +1110,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
PlayBGM(MUS_SHINKA);
|
PlayBGM(MUS_SHINKA);
|
||||||
sub_807F1A8(0, gText_CommunicationStandby5, 1);
|
DrawTextOnTradeWindow(0, gText_CommunicationStandby5, 1);
|
||||||
gTasks[taskID].tState++;
|
gTasks[taskID].tState++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1144,7 +1144,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
if (EvoScene_IsMonAnimFinished(sEvoStructPtr->preEvoSpriteID))
|
if (EvoScene_IsMonAnimFinished(sEvoStructPtr->preEvoSpriteID))
|
||||||
{
|
{
|
||||||
StringExpandPlaceholders(gStringVar4, gText_EllipsisQuestionMark);
|
StringExpandPlaceholders(gStringVar4, gText_EllipsisQuestionMark);
|
||||||
sub_807F1A8(0, gStringVar4, 1);
|
DrawTextOnTradeWindow(0, gStringVar4, 1);
|
||||||
gTasks[taskID].tEvoWasStopped = 1;
|
gTasks[taskID].tEvoWasStopped = 1;
|
||||||
gTasks[taskID].tState = 13;
|
gTasks[taskID].tState = 13;
|
||||||
}
|
}
|
||||||
@ -1155,7 +1155,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
BufferMoveToLearnIntoBattleTextBuff2();
|
BufferMoveToLearnIntoBattleTextBuff2();
|
||||||
PlayFanfare(MUS_FANFA1);
|
PlayFanfare(MUS_FANFA1);
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNLEARNEDMOVE - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNLEARNEDMOVE - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tLearnsFirstMove = 0x40; // re-used as a counter
|
gTasks[taskID].tLearnsFirstMove = 0x40; // re-used as a counter
|
||||||
gTasks[taskID].tState++;
|
gTasks[taskID].tState++;
|
||||||
}
|
}
|
||||||
@ -1172,7 +1172,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
{
|
{
|
||||||
BufferMoveToLearnIntoBattleTextBuff2();
|
BufferMoveToLearnIntoBattleTextBuff2();
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE1 - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE1 - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tLearnMoveState++;
|
gTasks[taskID].tLearnMoveState++;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -1180,7 +1180,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
if (!IsTextPrinterActive(0) && !IsSEPlaying())
|
if (!IsTextPrinterActive(0) && !IsSEPlaying())
|
||||||
{
|
{
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE2 - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE2 - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tLearnMoveState++;
|
gTasks[taskID].tLearnMoveState++;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -1188,7 +1188,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
if (!IsTextPrinterActive(0) && !IsSEPlaying())
|
if (!IsTextPrinterActive(0) && !IsSEPlaying())
|
||||||
{
|
{
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE3 - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_TRYTOLEARNMOVE3 - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tData7 = 5;
|
gTasks[taskID].tData7 = 5;
|
||||||
gTasks[taskID].tData8 = 9;
|
gTasks[taskID].tData8 = 9;
|
||||||
gTasks[taskID].tLearnMoveState++;
|
gTasks[taskID].tLearnMoveState++;
|
||||||
@ -1209,7 +1209,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
case 0:
|
case 0:
|
||||||
sEvoCursorPos = 0;
|
sEvoCursorPos = 0;
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_EMPTYSTRING3 - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_EMPTYSTRING3 - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tLearnMoveState = gTasks[taskID].tData7;
|
gTasks[taskID].tLearnMoveState = gTasks[taskID].tData7;
|
||||||
if (gTasks[taskID].tLearnMoveState == 5)
|
if (gTasks[taskID].tLearnMoveState == 5)
|
||||||
BeginNormalPaletteFade(0xFFFFFFFF, 0, 0, 0x10, RGB_BLACK);
|
BeginNormalPaletteFade(0xFFFFFFFF, 0, 0, 0x10, RGB_BLACK);
|
||||||
@ -1218,7 +1218,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
case -1:
|
case -1:
|
||||||
sEvoCursorPos = 1;
|
sEvoCursorPos = 1;
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_EMPTYSTRING3 - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_EMPTYSTRING3 - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tLearnMoveState = gTasks[taskID].tData8;
|
gTasks[taskID].tLearnMoveState = gTasks[taskID].tData8;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -1254,7 +1254,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
if (IsHMMove2(move))
|
if (IsHMMove2(move))
|
||||||
{
|
{
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_HMMOVESCANTBEFORGOTTEN - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_HMMOVESCANTBEFORGOTTEN - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tLearnMoveState = 11;
|
gTasks[taskID].tLearnMoveState = 11;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -1264,7 +1264,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
RemoveMonPPBonus(mon, var);
|
RemoveMonPPBonus(mon, var);
|
||||||
SetMonMoveSlot(mon, gMoveToLearn, var);
|
SetMonMoveSlot(mon, gMoveToLearn, var);
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_123POOF - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_123POOF - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tLearnMoveState++;
|
gTasks[taskID].tLearnMoveState++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1274,7 +1274,7 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
if (!IsTextPrinterActive(0) && !IsSEPlaying())
|
if (!IsTextPrinterActive(0) && !IsSEPlaying())
|
||||||
{
|
{
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNFORGOTMOVE - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_PKMNFORGOTMOVE - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tLearnMoveState++;
|
gTasks[taskID].tLearnMoveState++;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -1282,20 +1282,20 @@ static void Task_TradeEvolutionScene(u8 taskID)
|
|||||||
if (!IsTextPrinterActive(0) && !IsSEPlaying())
|
if (!IsTextPrinterActive(0) && !IsSEPlaying())
|
||||||
{
|
{
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_ANDELLIPSIS - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_ANDELLIPSIS - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tState = 18;
|
gTasks[taskID].tState = 18;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 9:
|
case 9:
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_STOPLEARNINGMOVE - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_STOPLEARNINGMOVE - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tData7 = 10;
|
gTasks[taskID].tData7 = 10;
|
||||||
gTasks[taskID].tData8 = 0;
|
gTasks[taskID].tData8 = 0;
|
||||||
gTasks[taskID].tLearnMoveState = 3;
|
gTasks[taskID].tLearnMoveState = 3;
|
||||||
break;
|
break;
|
||||||
case 10:
|
case 10:
|
||||||
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_DIDNOTLEARNMOVE - BATTLESTRINGS_ID_ADDER]);
|
BattleStringExpandPlaceholdersToDisplayedString(gBattleStringsTable[STRINGID_DIDNOTLEARNMOVE - BATTLESTRINGS_ID_ADDER]);
|
||||||
sub_807F1A8(0, gDisplayedStringBattle, 1);
|
DrawTextOnTradeWindow(0, gDisplayedStringBattle, 1);
|
||||||
gTasks[taskID].tState = 13;
|
gTasks[taskID].tState = 13;
|
||||||
break;
|
break;
|
||||||
case 11:
|
case 11:
|
||||||
|
@ -1516,17 +1516,13 @@ asm(".space 0x20"); //blank palette??
|
|||||||
|
|
||||||
#include "data/graphics/berry_fix.h"
|
#include "data/graphics/berry_fix.h"
|
||||||
|
|
||||||
// more trade stuff?
|
// Trade
|
||||||
|
|
||||||
const u16 gTradeMenu_Pal[] = INCBIN_U16("graphics/trade/menu.gbapal");
|
const u16 gTradeMenu_Pal[] = INCBIN_U16("graphics/trade/menu.gbapal");
|
||||||
const u16 gUnknown_08DDB444[] = INCBIN_U16("graphics/unknown/unknown_DDB444.gbapal");
|
const u16 gUnknown_08DDB444[] = INCBIN_U16("graphics/unknown/unknown_DDB444.gbapal");
|
||||||
const u8 gTradeMenu_Gfx[] = INCBIN_U8("graphics/trade/menu.4bpp");
|
const u8 gTradeMenu_Gfx[] = INCBIN_U8("graphics/trade/menu.4bpp");
|
||||||
const u8 gTradeButtons_Gfx[] = INCBIN_U8("graphics/trade/buttons.4bpp");
|
const u8 gTradeButtons_Gfx[] = INCBIN_U8("graphics/trade/buttons.4bpp");
|
||||||
|
|
||||||
const u16 gUnused_DDCEE4[] = INCBIN_U16("graphics/unused/unused_DDCEE4.bin");
|
const u16 gUnused_DDCEE4[] = INCBIN_U16("graphics/unused/unused_DDCEE4.bin");
|
||||||
|
|
||||||
const u16 gUnknown_08DDCF04[] = INCBIN_U16("graphics/unknown/unknown_DDCF04.bin");
|
const u16 gUnknown_08DDCF04[] = INCBIN_U16("graphics/unknown/unknown_DDCF04.bin");
|
||||||
|
|
||||||
const u16 gUnknown_08DDD704[] = INCBIN_U16("graphics/unknown/unknown_DDD704.bin"); // textbox tilemap??
|
const u16 gUnknown_08DDD704[] = INCBIN_U16("graphics/unknown/unknown_DDD704.bin"); // textbox tilemap??
|
||||||
|
|
||||||
const u16 gMessageBox_Pal[] = INCBIN_U16("graphics/text_window/message_box.gbapal");
|
const u16 gMessageBox_Pal[] = INCBIN_U16("graphics/text_window/message_box.gbapal");
|
||||||
|
@ -4983,19 +4983,19 @@ static void sub_81B5A8C(u8 spriteId, u16 hp, u16 maxhp)
|
|||||||
switch (GetHPBarLevel(hp, maxhp))
|
switch (GetHPBarLevel(hp, maxhp))
|
||||||
{
|
{
|
||||||
case HP_BAR_FULL:
|
case HP_BAR_FULL:
|
||||||
sub_80D32C8(&gSprites[spriteId], 0);
|
SetPartyHPBarSprite(&gSprites[spriteId], 0);
|
||||||
break;
|
break;
|
||||||
case HP_BAR_GREEN:
|
case HP_BAR_GREEN:
|
||||||
sub_80D32C8(&gSprites[spriteId], 1);
|
SetPartyHPBarSprite(&gSprites[spriteId], 1);
|
||||||
break;
|
break;
|
||||||
case HP_BAR_YELLOW:
|
case HP_BAR_YELLOW:
|
||||||
sub_80D32C8(&gSprites[spriteId], 2);
|
SetPartyHPBarSprite(&gSprites[spriteId], 2);
|
||||||
break;
|
break;
|
||||||
case HP_BAR_RED:
|
case HP_BAR_RED:
|
||||||
sub_80D32C8(&gSprites[spriteId], 3);
|
SetPartyHPBarSprite(&gSprites[spriteId], 3);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
sub_80D32C8(&gSprites[spriteId], 4);
|
SetPartyHPBarSprite(&gSprites[spriteId], 4);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1302,7 +1302,7 @@ void sub_80D328C(struct Sprite *sprite)
|
|||||||
DestroySprite(sprite);
|
DestroySprite(sprite);
|
||||||
}
|
}
|
||||||
|
|
||||||
void sub_80D32C8(struct Sprite *sprite, u8 animNum)
|
void SetPartyHPBarSprite(struct Sprite *sprite, u8 animNum)
|
||||||
{
|
{
|
||||||
sprite->animNum = animNum;
|
sprite->animNum = animNum;
|
||||||
sprite->animDelayCounter = 0;
|
sprite->animDelayCounter = 0;
|
||||||
|
@ -1540,7 +1540,7 @@ static const u8 gHandCursorTiles[] = INCBIN_U8("graphics/pokemon_storage/hand_cu
|
|||||||
static const u8 gHandCursorShadowTiles[] = INCBIN_U8("graphics/pokemon_storage/hand_cursor_shadow.4bpp");
|
static const u8 gHandCursorShadowTiles[] = INCBIN_U8("graphics/pokemon_storage/hand_cursor_shadow.4bpp");
|
||||||
|
|
||||||
// code
|
// code
|
||||||
void sub_80C6D80(const u8 *string, void *dst, u8 arg2, u8 arg3, s32 arg4)
|
void sub_80C6D80(const u8 *string, void *dst, u8 zero1, u8 zero2, s32 arg4)
|
||||||
{
|
{
|
||||||
s32 i, val, val2;
|
s32 i, val, val2;
|
||||||
u16 windowId;
|
u16 windowId;
|
||||||
@ -1551,14 +1551,14 @@ void sub_80C6D80(const u8 *string, void *dst, u8 arg2, u8 arg3, s32 arg4)
|
|||||||
winTemplate.width = 24;
|
winTemplate.width = 24;
|
||||||
winTemplate.height = 2;
|
winTemplate.height = 2;
|
||||||
windowId = AddWindow(&winTemplate);
|
windowId = AddWindow(&winTemplate);
|
||||||
FillWindowPixelBuffer(windowId, PIXEL_FILL(arg3));
|
FillWindowPixelBuffer(windowId, PIXEL_FILL(zero2));
|
||||||
tileData1 = (u8*) GetWindowAttribute(windowId, WINDOW_TILE_DATA);
|
tileData1 = (u8*) GetWindowAttribute(windowId, WINDOW_TILE_DATA);
|
||||||
tileData2 = (winTemplate.width * 32) + tileData1;
|
tileData2 = (winTemplate.width * 32) + tileData1;
|
||||||
|
|
||||||
if (!arg2)
|
if (!zero1)
|
||||||
txtColor[0] = 0;
|
txtColor[0] = TEXT_COLOR_TRANSPARENT;
|
||||||
else
|
else
|
||||||
txtColor[0] = arg3;
|
txtColor[0] = zero2;
|
||||||
txtColor[1] = 0xF;
|
txtColor[1] = 0xF;
|
||||||
txtColor[2] = 0xE;
|
txtColor[2] = 0xE;
|
||||||
AddTextPrinterParameterized4(windowId, 1, 0, 1, 0, 0, txtColor, -1, string);
|
AddTextPrinterParameterized4(windowId, 1, 0, 1, 0, 0, txtColor, -1, string);
|
||||||
@ -1580,7 +1580,7 @@ void sub_80C6D80(const u8 *string, void *dst, u8 arg2, u8 arg3, s32 arg4)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (val2 > 0)
|
if (val2 > 0)
|
||||||
CpuFill16((arg3 << 4) | arg3, dst, (u32)(val2) * 0x100);
|
CpuFill16((zero2 << 4) | zero2, dst, (u32)(val2) * 0x100);
|
||||||
|
|
||||||
RemoveWindow(windowId);
|
RemoveWindow(windowId);
|
||||||
}
|
}
|
||||||
|
1993
src/trade.c
1993
src/trade.c
File diff suppressed because it is too large
Load Diff
@ -2347,8 +2347,8 @@ void sub_8013F90(u8 taskId)
|
|||||||
{
|
{
|
||||||
memcpy(gUnknown_020321C0, gBlockRecvBuffer[GetMultiplayerId() ^ 1], sizeof(struct MailStruct) * PARTY_SIZE);
|
memcpy(gUnknown_020321C0, gBlockRecvBuffer[GetMultiplayerId() ^ 1], sizeof(struct MailStruct) * PARTY_SIZE);
|
||||||
ResetBlockReceivedFlags();
|
ResetBlockReceivedFlags();
|
||||||
gSelectedTradeMonPositions[0] = monId;
|
gSelectedTradeMonPositions[TRADE_PLAYER] = monId;
|
||||||
gSelectedTradeMonPositions[1] = PARTY_SIZE;
|
gSelectedTradeMonPositions[TRADE_PARTNER] = PARTY_SIZE;
|
||||||
gMain.savedCallback = CB2_ReturnToField;
|
gMain.savedCallback = CB2_ReturnToField;
|
||||||
SetMainCallback2(sub_807AE50);
|
SetMainCallback2(sub_807AE50);
|
||||||
sub_801807C(&gUnknown_02022C40);
|
sub_801807C(&gUnknown_02022C40);
|
||||||
|
Loading…
Reference in New Issue
Block a user