mirror of
https://github.com/pret/pokeruby.git
synced 2025-04-01 07:41:45 +00:00
Merge remote-tracking branch 'origin/master' into de/integrate-data-includes
Conflicts: asm/battle_anim_8137220.s asm-de/battle_message.s
This commit is contained in:
commit
2cae14cf5a
@ -16,7 +16,7 @@ BufferStringBattle: @ 8120AA8
|
||||
lsls r0, 16
|
||||
lsrs r7, r0, 16
|
||||
movs r6, 0
|
||||
ldr r5, _08120B70 @ =gBufferedMoves
|
||||
ldr r5, _08120B70 @ =gSelectedOrderFromParty
|
||||
ldr r4, _08120B74 @ =gActiveBank
|
||||
ldrb r1, [r4]
|
||||
lsls r1, 9
|
||||
@ -73,7 +73,7 @@ _08120B10:
|
||||
movs r2, 0
|
||||
ldr r0, _08120B9C @ =gBattleTextBuff1
|
||||
mov r8, r0
|
||||
ldr r3, _08120B70 @ =gBufferedMoves
|
||||
ldr r3, _08120B70 @ =gSelectedOrderFromParty
|
||||
ldr r1, _08120BA4 @ =gBattleTextBuff2
|
||||
mov r12, r1
|
||||
ldr r5, _08120BA8 @ =gBattleTextBuff3
|
||||
@ -111,7 +111,7 @@ _08120B64:
|
||||
ldr r0, [r0]
|
||||
mov pc, r0
|
||||
.align 2, 0
|
||||
_08120B70: .4byte gBufferedMoves
|
||||
_08120B70: .4byte gSelectedOrderFromParty
|
||||
_08120B74: .4byte gActiveBank
|
||||
_08120B78: .4byte gUnknown_02023A64
|
||||
_08120B7C: .4byte gLastUsedItem
|
||||
@ -424,7 +424,7 @@ _d08120E0C: .4byte 0x0000ffff
|
||||
_08120DE8:
|
||||
mov r0, r10
|
||||
bl sub_8121D1C
|
||||
ldr r0, _08120E14 @ =gBufferedMoves
|
||||
ldr r0, _08120E14 @ =gSelectedOrderFromParty
|
||||
ldr r2, [r0]
|
||||
ldrh r1, [r2]
|
||||
movs r0, 0xB1
|
||||
@ -443,7 +443,7 @@ _08120DE8:
|
||||
bl StringCopy
|
||||
b _08120E38
|
||||
.align 2, 0
|
||||
_08120E14: .4byte gBufferedMoves
|
||||
_08120E14: .4byte gSelectedOrderFromParty
|
||||
_08120E18: .4byte gBattleTextBuff2
|
||||
_08120E1C: .4byte gUnknown_08401674
|
||||
_08120E20: .4byte 0x02000000
|
||||
@ -1309,7 +1309,7 @@ _081215E8:
|
||||
.align 2, 0
|
||||
_081215F4: .4byte gBattlePartyID
|
||||
_081215F8:
|
||||
ldr r0, _08de121568 @ =gBufferedMoves
|
||||
ldr r0, _08de121568 @ =gSelectedOrderFromParty
|
||||
ldr r2, [r0]
|
||||
ldrh r1, [r2]
|
||||
movs r0, 0xB1
|
||||
@ -1321,14 +1321,14 @@ _081215F8:
|
||||
adds r0, r3
|
||||
b _08de12158C
|
||||
.align 2, 0
|
||||
_08de121568: .4byte gBufferedMoves
|
||||
_08de121568: .4byte gSelectedOrderFromParty
|
||||
_08de12156C: .4byte 0x02000000
|
||||
_08de121570: .4byte 0x000160a0
|
||||
_08de121574:
|
||||
ldrh r1, [r2]
|
||||
b _08de1215AA
|
||||
_08121620:
|
||||
ldr r0, _08de121598 @ =gBufferedMoves
|
||||
ldr r0, _08de121598 @ =gSelectedOrderFromParty
|
||||
ldr r2, [r0]
|
||||
ldrh r1, [r2, 0x2]
|
||||
movs r0, 0xB1
|
||||
@ -1345,7 +1345,7 @@ _08de12158C:
|
||||
adds r4, r0, r1
|
||||
b _081219E6
|
||||
.align 2, 0
|
||||
_08de121598: .4byte gBufferedMoves
|
||||
_08de121598: .4byte gSelectedOrderFromParty
|
||||
_08de12159C: .4byte 0x02000000
|
||||
_08de1215A0: .4byte 0x000160a0
|
||||
_08de1215A4: .4byte gUnknown_08401674
|
||||
@ -2213,7 +2213,7 @@ sub_8121D1C: @ 8121D1C
|
||||
push {r4,r5,lr}
|
||||
adds r4, r0, 0
|
||||
movs r2, 0
|
||||
ldr r5, _08121D50 @ =gBufferedMoves
|
||||
ldr r5, _08121D50 @ =gSelectedOrderFromParty
|
||||
ldr r3, _08121D54 @ =gUnknown_084016BC
|
||||
_08121D26:
|
||||
cmp r2, 0x4
|
||||
@ -2238,7 +2238,7 @@ _08121D3C:
|
||||
bl StringCopy
|
||||
b _08121D68
|
||||
.align 2, 0
|
||||
_08121D50: .4byte gBufferedMoves
|
||||
_08121D50: .4byte gSelectedOrderFromParty
|
||||
_08121D54: .4byte gUnknown_084016BC
|
||||
_08121D58: .4byte gUnknown_08400E5E
|
||||
_08121D5C:
|
||||
@ -2268,7 +2268,7 @@ _08121D7E:
|
||||
cmp r0, 0xFF
|
||||
bne _08121D7C
|
||||
ldr r1, _08121DB4 @ =gUnknown_084016BC
|
||||
ldr r5, _08121DB8 @ =gBufferedMoves
|
||||
ldr r5, _08121DB8 @ =gSelectedOrderFromParty
|
||||
movs r0, 0
|
||||
lsls r0, 1
|
||||
adds r2, r0, r1
|
||||
@ -2295,7 +2295,7 @@ _08121DA8:
|
||||
mov pc, r0
|
||||
.align 2, 0
|
||||
_08121DB4: .4byte gUnknown_084016BC
|
||||
_08121DB8: .4byte gBufferedMoves
|
||||
_08121DB8: .4byte gSelectedOrderFromParty
|
||||
_08121DBC: .4byte _08121DC0
|
||||
.align 2, 0
|
||||
_08121DC0:
|
||||
|
5484
asm/battle_6.s
5484
asm/battle_6.s
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -16,7 +16,7 @@ BufferStringBattle: @ 8120AA8
|
||||
lsls r0, 16
|
||||
lsrs r7, r0, 16
|
||||
movs r6, 0
|
||||
ldr r5, _08120B70 @ =gBufferedMoves
|
||||
ldr r5, _08120B70 @ =gSelectedOrderFromParty
|
||||
ldr r4, _08120B74 @ =gActiveBank
|
||||
ldrb r1, [r4]
|
||||
lsls r1, 9
|
||||
@ -73,7 +73,7 @@ _08120B10:
|
||||
movs r2, 0
|
||||
ldr r0, _08120B9C @ =gBattleTextBuff1
|
||||
mov r8, r0
|
||||
ldr r3, _08120B70 @ =gBufferedMoves
|
||||
ldr r3, _08120B70 @ =gSelectedOrderFromParty
|
||||
ldr r1, _08120BA4 @ =gBattleTextBuff2
|
||||
mov r12, r1
|
||||
ldr r5, _08120BA8 @ =gBattleTextBuff3
|
||||
@ -111,7 +111,7 @@ _08120B64:
|
||||
ldr r0, [r0]
|
||||
mov pc, r0
|
||||
.align 2, 0
|
||||
_08120B70: .4byte gBufferedMoves
|
||||
_08120B70: .4byte gSelectedOrderFromParty
|
||||
_08120B74: .4byte gActiveBank
|
||||
_08120B78: .4byte gUnknown_02023A64
|
||||
_08120B7C: .4byte gLastUsedItem
|
||||
@ -414,7 +414,7 @@ _08120DE4: .4byte gUnknown_08400622
|
||||
_08120DE8:
|
||||
mov r0, r10
|
||||
bl sub_8121D1C
|
||||
ldr r0, _08120E14 @ =gBufferedMoves
|
||||
ldr r0, _08120E14 @ =gSelectedOrderFromParty
|
||||
ldr r2, [r0]
|
||||
ldrh r1, [r2]
|
||||
movs r0, 0xB1
|
||||
@ -433,7 +433,7 @@ _08120DE8:
|
||||
bl StringCopy
|
||||
b _08120E38
|
||||
.align 2, 0
|
||||
_08120E14: .4byte gBufferedMoves
|
||||
_08120E14: .4byte gSelectedOrderFromParty
|
||||
_08120E18: .4byte gBattleTextBuff2
|
||||
_08120E1C: .4byte gUnknown_08401674
|
||||
_08120E20: .4byte 0x02000000
|
||||
@ -1368,7 +1368,7 @@ _081215E8:
|
||||
.align 2, 0
|
||||
_081215F4: .4byte gBattlePartyID
|
||||
_081215F8:
|
||||
ldr r0, _08121610 @ =gBufferedMoves
|
||||
ldr r0, _08121610 @ =gSelectedOrderFromParty
|
||||
ldr r2, [r0]
|
||||
ldrh r1, [r2]
|
||||
movs r0, 0xB1
|
||||
@ -1380,14 +1380,14 @@ _081215F8:
|
||||
adds r0, r2
|
||||
b _08121634
|
||||
.align 2, 0
|
||||
_08121610: .4byte gBufferedMoves
|
||||
_08121610: .4byte gSelectedOrderFromParty
|
||||
_08121614: .4byte 0x02000000
|
||||
_08121618: .4byte 0x000160a0
|
||||
_0812161C:
|
||||
ldrh r1, [r2]
|
||||
b _08121652
|
||||
_08121620:
|
||||
ldr r0, _08121640 @ =gBufferedMoves
|
||||
ldr r0, _08121640 @ =gSelectedOrderFromParty
|
||||
ldr r2, [r0]
|
||||
ldrh r1, [r2, 0x2]
|
||||
movs r0, 0xB1
|
||||
@ -1404,7 +1404,7 @@ _08121634:
|
||||
adds r4, r0, r1
|
||||
b _081219E6
|
||||
.align 2, 0
|
||||
_08121640: .4byte gBufferedMoves
|
||||
_08121640: .4byte gSelectedOrderFromParty
|
||||
_08121644: .4byte 0x02000000
|
||||
_08121648: .4byte 0x000160a0
|
||||
_0812164C: .4byte gUnknown_08401674
|
||||
@ -2274,7 +2274,7 @@ sub_8121D1C: @ 8121D1C
|
||||
push {r4,r5,lr}
|
||||
adds r4, r0, 0
|
||||
movs r2, 0
|
||||
ldr r5, _08121D50 @ =gBufferedMoves
|
||||
ldr r5, _08121D50 @ =gSelectedOrderFromParty
|
||||
ldr r3, _08121D54 @ =gUnknown_084016BC
|
||||
_08121D26:
|
||||
cmp r2, 0x4
|
||||
@ -2299,7 +2299,7 @@ _08121D3C:
|
||||
bl StringCopy
|
||||
b _08121D68
|
||||
.align 2, 0
|
||||
_08121D50: .4byte gBufferedMoves
|
||||
_08121D50: .4byte gSelectedOrderFromParty
|
||||
_08121D54: .4byte gUnknown_084016BC
|
||||
_08121D58: .4byte gUnknown_08400E5E
|
||||
_08121D5C:
|
||||
@ -2329,7 +2329,7 @@ _08121D7E:
|
||||
cmp r0, 0xFF
|
||||
bne _08121D7C
|
||||
ldr r1, _08121DB4 @ =gUnknown_084016BC
|
||||
ldr r5, _08121DB8 @ =gBufferedMoves
|
||||
ldr r5, _08121DB8 @ =gSelectedOrderFromParty
|
||||
movs r0, 0
|
||||
lsls r0, 1
|
||||
adds r2, r0, r1
|
||||
@ -2356,7 +2356,7 @@ _08121DA8:
|
||||
mov pc, r0
|
||||
.align 2, 0
|
||||
_08121DB4: .4byte gUnknown_084016BC
|
||||
_08121DB8: .4byte gBufferedMoves
|
||||
_08121DB8: .4byte gSelectedOrderFromParty
|
||||
_08121DBC: .4byte _08121DC0
|
||||
.align 2, 0
|
||||
_08121DC0:
|
||||
|
@ -2324,7 +2324,7 @@ _08135750: .4byte 0x00000564
|
||||
_08135754:
|
||||
movs r2, 0
|
||||
ldr r4, _0813576C @ =gSaveBlock2 + 0x565
|
||||
ldr r3, _08135770 @ =gBufferedMoves
|
||||
ldr r3, _08135770 @ =gSelectedOrderFromParty
|
||||
_0813575A:
|
||||
adds r0, r2, r4
|
||||
adds r1, r2, r3
|
||||
@ -2336,7 +2336,7 @@ _0813575A:
|
||||
b _0813589A
|
||||
.align 2, 0
|
||||
_0813576C: .4byte gSaveBlock2 + 0x565
|
||||
_08135770: .4byte gBufferedMoves
|
||||
_08135770: .4byte gSelectedOrderFromParty
|
||||
_08135774:
|
||||
ldr r3, _081357C0 @ =0x00000564
|
||||
adds r0, r5, r3
|
||||
@ -2665,7 +2665,7 @@ _08135A10: .4byte 0x00000554
|
||||
sub_8135A14: @ 8135A14
|
||||
push {r4,lr}
|
||||
movs r2, 0
|
||||
ldr r4, _08135A34 @ =gBufferedMoves
|
||||
ldr r4, _08135A34 @ =gSelectedOrderFromParty
|
||||
ldr r3, _08135A38 @ =gSaveBlock2 + 0x565
|
||||
_08135A1C:
|
||||
adds r0, r2, r4
|
||||
@ -2680,7 +2680,7 @@ _08135A1C:
|
||||
pop {r0}
|
||||
bx r0
|
||||
.align 2, 0
|
||||
_08135A34: .4byte gBufferedMoves
|
||||
_08135A34: .4byte gSelectedOrderFromParty
|
||||
_08135A38: .4byte gSaveBlock2 + 0x565
|
||||
thumb_func_end sub_8135A14
|
||||
|
||||
|
2509
asm/choose_party.s
2509
asm/choose_party.s
File diff suppressed because it is too large
Load Diff
@ -1,56 +0,0 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "constants/constants.inc"
|
||||
|
||||
.section .rodata
|
||||
|
||||
.align 2
|
||||
gUnknown_084017B0:: @ 84017B0
|
||||
.4byte OtherText_Summary, sub_812265C
|
||||
.4byte OtherText_Enter2, sub_8122694
|
||||
.4byte OtherText_NoEntry, sub_8122770
|
||||
.4byte gUnknownText_Exit, sub_8122838
|
||||
|
||||
gUnknown_084017D0:: @ 84017D0
|
||||
.byte 1, 0, 3
|
||||
|
||||
gUnknown_084017D3: @ 84017D3
|
||||
.byte 2, 0, 3
|
||||
|
||||
gUnknown_084017D6: @ 84017D6
|
||||
.byte 0, 3
|
||||
|
||||
.align 2
|
||||
gUnknown_084017D8:: @ 84017D8
|
||||
.byte 3, 9
|
||||
.space 2
|
||||
.4byte gUnknown_084017D0
|
||||
|
||||
.byte 3, 9
|
||||
.space 2
|
||||
.4byte gUnknown_084017D3
|
||||
|
||||
.byte 2, 9
|
||||
.space 2
|
||||
.4byte gUnknown_084017D6
|
||||
|
||||
.align 2
|
||||
gUnknown_084017F0:: @ 84017F0
|
||||
.4byte OtherText_Store, sub_8122F70
|
||||
.4byte OtherText_Summary, sub_81230BC
|
||||
.4byte gUnknownText_Exit, sub_81230F4
|
||||
|
||||
gUnknown_08401808:: @ 8401808
|
||||
.byte 0, 1, 2
|
||||
|
||||
gUnknown_0840180B:: @ 840180B
|
||||
.byte 1, 2
|
||||
|
||||
.align 2
|
||||
gUnknown_08401810:: @ 8401810
|
||||
.byte 3, 9
|
||||
.space 2
|
||||
.4byte gUnknown_08401808
|
||||
|
||||
.byte 2, 9
|
||||
.space 2
|
||||
.4byte gUnknown_0840180B
|
@ -185,7 +185,6 @@ struct Struct2017810
|
||||
u8 unk1_0:1;
|
||||
u8 unk2;
|
||||
u8 unk3;
|
||||
//u8 filler2[2];
|
||||
u8 unk4;
|
||||
u8 unk5;
|
||||
u8 unk6;
|
||||
@ -198,13 +197,21 @@ struct Struct2017810
|
||||
struct Struct2017840
|
||||
{
|
||||
u16 unk0;
|
||||
u8 filler2[7];
|
||||
u8 filler2[6];
|
||||
u8 unk8;
|
||||
u8 unk9_0:1;
|
||||
};
|
||||
|
||||
struct Struct20238C8
|
||||
{
|
||||
u8 unk0_0:7;
|
||||
u8 unk0_7:1;
|
||||
};
|
||||
|
||||
extern struct UnkBattleStruct1 unk_2016A00;
|
||||
extern struct UnkBattleStruct4 gDisableStructs[];
|
||||
extern struct AI_ThinkingStruct gAIThinkingSpace;
|
||||
extern struct Struct20238C8 gUnknown_020238C8;
|
||||
|
||||
// TODO: move ewram to global.h
|
||||
extern u8 ewram[];
|
||||
|
@ -1,7 +1,7 @@
|
||||
#ifndef GUARD_BATTLE_MESSAGE_H
|
||||
#define GUARD_BATTLE_MESSAGE_H
|
||||
|
||||
void StrCpyDecodeToDisplayedStringBattle(u8 *);
|
||||
void StrCpyDecodeToDisplayedStringBattle(const u8 *);
|
||||
void StrCpyDecodeBattle(const u8 *, u8 *);
|
||||
|
||||
#endif // GUARD_BATTLE_MESSAGE_H
|
||||
|
@ -1,26 +1,9 @@
|
||||
#ifndef GUARD_BATTLE_PARTY_MENU_H
|
||||
#define GUARD_BATTLE_PARTY_MENU_H
|
||||
|
||||
#include "task.h"
|
||||
|
||||
// TODO: Unify all of the 0x0201B000 structs
|
||||
struct Struct201B000
|
||||
{
|
||||
u8 filler0[0x259];
|
||||
u8 unk259;
|
||||
u8 filler25A[6];
|
||||
u8 unk260;
|
||||
u8 filler261[1];
|
||||
u8 unk262;
|
||||
s16 unk264;
|
||||
s16 unk266;
|
||||
};
|
||||
|
||||
extern u8 unk_2000000[];
|
||||
#define EWRAM_1609D unk_2000000[0x1609D]
|
||||
|
||||
void SetUpBattlePokemonMenu(u8);
|
||||
|
||||
#define EWRAM_1609D unk_2000000[0x1609D]
|
||||
#define EWRAM_1B000 (*(struct Struct201B000 *)(unk_2000000 + 0x1B000))
|
||||
|
||||
#endif
|
||||
|
@ -3,6 +3,11 @@
|
||||
|
||||
void sub_8121E10(void);
|
||||
void sub_8121E34(void);
|
||||
void sub_8123138(u8);
|
||||
bool8 sub_8121E78(void);
|
||||
void sub_81222B0(u8 taskId);
|
||||
bool8 sub_8122854(void);
|
||||
void sub_8122A48(u8 taskId);
|
||||
void sub_8122E0C(u8 taskId);
|
||||
void sub_8123138(u8 taskId);
|
||||
|
||||
#endif // GUARD_CHOOSE_PARTY_H
|
||||
|
@ -625,10 +625,11 @@ struct Pokedex
|
||||
|
||||
struct SaveBlock2_Sub
|
||||
{
|
||||
/*0x0000, 0x00A4*/ u8 filler_000[0x3D8];
|
||||
/*0x0000, 0x00A8*/ u8 filler_000[0x3D8];
|
||||
/*0x03D8, 0x0480*/ u16 var_480;
|
||||
/*0x03DA, 0x0482*/ u16 var_482;
|
||||
/*0x03DC, 0x0484*/ u8 filler_3DC[0xD1];
|
||||
/*0x03DC, 0x0484*/ u8 filler_3DC[0xD0];
|
||||
/*0x04AC, 0x0554*/ u8 var_4AC;
|
||||
/*0x04AD, 0x0555*/ u8 var_4AD;
|
||||
/*0x04AE, 0x0556*/ u8 var_4AE;
|
||||
/*0x04AF, 0x0557*/ u8 var_4AF;
|
||||
|
@ -16,6 +16,44 @@ struct PartyPopupMenu
|
||||
const u8 *unk4;
|
||||
};
|
||||
|
||||
// TODO: Unify these two structs
|
||||
|
||||
#define DATA_COUNT (6)
|
||||
struct Unk201B000
|
||||
{
|
||||
//u8 filler0[0x260];
|
||||
struct Pokemon unk0[6];
|
||||
u8 filler258[1];
|
||||
u8 unk259;
|
||||
u8 filler25A[6];
|
||||
u8 unk260;
|
||||
u8 unk261;
|
||||
u8 unk262;
|
||||
u8 unk263;
|
||||
s16 unk264[DATA_COUNT * 2]; // This may be a union
|
||||
u8 filler27C[2];
|
||||
s16 unk27E;
|
||||
s16 unk280;
|
||||
s16 unk282;
|
||||
};
|
||||
|
||||
struct Struct201B000
|
||||
{
|
||||
u8 filler0[0x259];
|
||||
u8 unk259;
|
||||
u8 filler25A[6];
|
||||
u8 unk260;
|
||||
u8 filler261[1];
|
||||
u8 unk262;
|
||||
s16 unk264;
|
||||
s16 unk266;
|
||||
};
|
||||
|
||||
extern u8 ewram[];
|
||||
#define ewram1B000 (*(struct Unk201B000 *)(ewram + 0x1B000))
|
||||
#define ewram1B000_alt (*(struct Struct201B000 *)(ewram + 0x1B000))
|
||||
#define EWRAM_1B000 ewram1B000_alt
|
||||
|
||||
void sub_806AEDC(void);
|
||||
void sub_806AF4C();
|
||||
void OpenPartyMenu(u8, u8);
|
||||
|
@ -182,41 +182,41 @@ struct PokemonSubstruct2
|
||||
|
||||
struct PokemonSubstruct3
|
||||
{
|
||||
/* 0x00 */ u8 pokerus;
|
||||
/* 0x01 */ u8 metLocation;
|
||||
/*0x00*/ u8 pokerus;
|
||||
/*0x01*/ u8 metLocation;
|
||||
|
||||
/* 0x02 */ u16 metLevel:7;
|
||||
/* 0x02 */ u16 metGame:4;
|
||||
/* 0x03 */ u16 pokeball:4;
|
||||
/* 0x03 */ u16 otGender:1;
|
||||
/*0x02*/ u16 metLevel:7;
|
||||
/*0x02*/ u16 metGame:4;
|
||||
/*0x03*/ u16 pokeball:4;
|
||||
/*0x03*/ u16 otGender:1;
|
||||
|
||||
/* 0x04 */ u32 hpIV:5;
|
||||
/* 0x04 */ u32 attackIV:5;
|
||||
/* 0x05 */ u32 defenseIV:5;
|
||||
/* 0x05 */ u32 speedIV:5;
|
||||
/* 0x05 */ u32 spAttackIV:5;
|
||||
/* 0x06 */ u32 spDefenseIV:5;
|
||||
/* 0x07 */ u32 isEgg:1;
|
||||
/* 0x07 */ u32 altAbility:1;
|
||||
/*0x04*/ u32 hpIV:5;
|
||||
/*0x04*/ u32 attackIV:5;
|
||||
/*0x05*/ u32 defenseIV:5;
|
||||
/*0x05*/ u32 speedIV:5;
|
||||
/*0x05*/ u32 spAttackIV:5;
|
||||
/*0x06*/ u32 spDefenseIV:5;
|
||||
/*0x07*/ u32 isEgg:1;
|
||||
/*0x07*/ u32 altAbility:1;
|
||||
|
||||
/* 0x08 */ u32 coolRibbon:3;
|
||||
/* 0x08 */ u32 beautyRibbon:3;
|
||||
/* 0x08 */ u32 cuteRibbon:3;
|
||||
/* 0x09 */ u32 smartRibbon:3;
|
||||
/* 0x09 */ u32 toughRibbon:3;
|
||||
/* 0x09 */ u32 championRibbon:1;
|
||||
/* 0x0A */ u32 winningRibbon:1;
|
||||
/* 0x0A */ u32 victoryRibbon:1;
|
||||
/* 0x0A */ u32 artistRibbon:1;
|
||||
/* 0x0A */ u32 effortRibbon:1;
|
||||
/* 0x0A */ u32 giftRibbon1:1;
|
||||
/* 0x0A */ u32 giftRibbon2:1;
|
||||
/* 0x0A */ u32 giftRibbon3:1;
|
||||
/* 0x0A */ u32 giftRibbon4:1;
|
||||
/* 0x0B */ u32 giftRibbon5:1;
|
||||
/* 0x0B */ u32 giftRibbon6:1;
|
||||
/* 0x0B */ u32 giftRibbon7:1;
|
||||
/* 0x0B */ u32 fatefulEncounter:5; // unused in Ruby/Sapphire, but the high bit must be set for Mew/Deoxys to obey in FR/LG/Emerald
|
||||
/*0x08*/ u32 coolRibbon:3;
|
||||
/*0x08*/ u32 beautyRibbon:3;
|
||||
/*0x08*/ u32 cuteRibbon:3;
|
||||
/*0x09*/ u32 smartRibbon:3;
|
||||
/*0x09*/ u32 toughRibbon:3;
|
||||
/*0x09*/ u32 championRibbon:1;
|
||||
/*0x0A*/ u32 winningRibbon:1;
|
||||
/*0x0A*/ u32 victoryRibbon:1;
|
||||
/*0x0A*/ u32 artistRibbon:1;
|
||||
/*0x0A*/ u32 effortRibbon:1;
|
||||
/*0x0A*/ u32 giftRibbon1:1;
|
||||
/*0x0A*/ u32 giftRibbon2:1;
|
||||
/*0x0A*/ u32 giftRibbon3:1;
|
||||
/*0x0A*/ u32 giftRibbon4:1;
|
||||
/*0x0B*/ u32 giftRibbon5:1;
|
||||
/*0x0B*/ u32 giftRibbon6:1;
|
||||
/*0x0B*/ u32 giftRibbon7:1;
|
||||
/*0x0B*/ u32 fatefulEncounter:5; // unused in Ruby/Sapphire, but the high bit must be set for Mew/Deoxys to obey in FR/LG/Emerald
|
||||
};
|
||||
|
||||
union PokemonSubstruct
|
||||
@ -230,39 +230,39 @@ union PokemonSubstruct
|
||||
|
||||
struct BoxPokemon
|
||||
{
|
||||
u32 personality;
|
||||
u32 otId;
|
||||
u8 nickname[POKEMON_NAME_LENGTH];
|
||||
u8 language;
|
||||
u8 isBadEgg:1;
|
||||
u8 hasSpecies:1;
|
||||
u8 isEgg:1;
|
||||
u8 unused:5;
|
||||
u8 otName[OT_NAME_LENGTH];
|
||||
u8 markings;
|
||||
u16 checksum;
|
||||
u16 unknown;
|
||||
/*0x00*/ u32 personality;
|
||||
/*0x04*/ u32 otId;
|
||||
/*0x08*/ u8 nickname[POKEMON_NAME_LENGTH];
|
||||
/*0x12*/ u8 language;
|
||||
/*0x13*/ u8 isBadEgg:1;
|
||||
u8 hasSpecies:1;
|
||||
u8 isEgg:1;
|
||||
u8 unused:5;
|
||||
/*0x14*/ u8 otName[OT_NAME_LENGTH];
|
||||
/*0x1B*/ u8 markings;
|
||||
/*0x1C*/ u16 checksum;
|
||||
/*0x1E*/ u16 unknown;
|
||||
|
||||
union
|
||||
{
|
||||
u32 raw[12];
|
||||
union PokemonSubstruct substructs[4];
|
||||
} secure;
|
||||
};
|
||||
}; /*size = 0x50*/
|
||||
|
||||
struct Pokemon
|
||||
{
|
||||
struct BoxPokemon box;
|
||||
u32 status;
|
||||
u8 level;
|
||||
u8 mail;
|
||||
u16 hp;
|
||||
u16 maxHP;
|
||||
u16 attack;
|
||||
u16 defense;
|
||||
u16 speed;
|
||||
u16 spAttack;
|
||||
u16 spDefense;
|
||||
/*0x00*/ struct BoxPokemon box;
|
||||
/*0x50*/ u32 status;
|
||||
/*0x54*/ u8 level;
|
||||
/*0x55*/ u8 mail;
|
||||
/*0x56*/ u16 hp;
|
||||
/*0x58*/ u16 maxHP;
|
||||
/*0x5A*/ u16 attack;
|
||||
/*0x5C*/ u16 defense;
|
||||
/*0x5E*/ u16 speed;
|
||||
/*0x60*/ u16 spAttack;
|
||||
/*0x62*/ u16 spDefense;
|
||||
};
|
||||
|
||||
struct UnknownPokemonStruct
|
||||
@ -294,73 +294,73 @@ struct UnknownPokemonStruct
|
||||
|
||||
struct BattlePokemon
|
||||
{
|
||||
/* 0x00 */ u16 species;
|
||||
/* 0x02 */ u16 attack;
|
||||
/* 0x04 */ u16 defense;
|
||||
/* 0x06 */ u16 speed;
|
||||
/* 0x08 */ u16 spAttack;
|
||||
/* 0x0A */ u16 spDefense;
|
||||
/* 0x0C */ u16 moves[4];
|
||||
/* 0x14 */ u32 hpIV:5;
|
||||
/* 0x14 */ u32 attackIV:5;
|
||||
/* 0x15 */ u32 defenseIV:5;
|
||||
/* 0x15 */ u32 speedIV:5;
|
||||
/* 0x16 */ u32 spAttackIV:5;
|
||||
/* 0x17 */ u32 spDefenseIV:5;
|
||||
/* 0x17 */ u32 isEgg:1;
|
||||
/* 0x17 */ u32 altAbility:1;
|
||||
/* 0x18 */ s8 statStages[8];
|
||||
/* 0x20 */ u8 ability;
|
||||
/* 0x21 */ u8 type1;
|
||||
/* 0x22 */ u8 type2;
|
||||
/* 0x23 */ u8 unknown;
|
||||
/* 0x24 */ u8 pp[4];
|
||||
/* 0x28 */ u16 hp;
|
||||
/* 0x2A */ u8 level;
|
||||
/* 0x2B */ u8 friendship;
|
||||
/* 0x2C */ u16 maxHP;
|
||||
/* 0x2E */ u16 item;
|
||||
/* 0x30 */ u8 nickname[POKEMON_NAME_LENGTH + 1];
|
||||
/* 0x3B */ u8 ppBonuses;
|
||||
/* 0x3C */ u8 otName[8];
|
||||
/* 0x44 */ u32 experience;
|
||||
/* 0x48 */ u32 personality;
|
||||
/* 0x4C */ u32 status1;
|
||||
/* 0x50 */ u32 status2;
|
||||
/* 0x54 */ u32 otId;
|
||||
/*0x00*/ u16 species;
|
||||
/*0x02*/ u16 attack;
|
||||
/*0x04*/ u16 defense;
|
||||
/*0x06*/ u16 speed;
|
||||
/*0x08*/ u16 spAttack;
|
||||
/*0x0A*/ u16 spDefense;
|
||||
/*0x0C*/ u16 moves[4];
|
||||
/*0x14*/ u32 hpIV:5;
|
||||
/*0x14*/ u32 attackIV:5;
|
||||
/*0x15*/ u32 defenseIV:5;
|
||||
/*0x15*/ u32 speedIV:5;
|
||||
/*0x16*/ u32 spAttackIV:5;
|
||||
/*0x17*/ u32 spDefenseIV:5;
|
||||
/*0x17*/ u32 isEgg:1;
|
||||
/*0x17*/ u32 altAbility:1;
|
||||
/*0x18*/ s8 statStages[8];
|
||||
/*0x20*/ u8 ability;
|
||||
/*0x21*/ u8 type1;
|
||||
/*0x22*/ u8 type2;
|
||||
/*0x23*/ u8 unknown;
|
||||
/*0x24*/ u8 pp[4];
|
||||
/*0x28*/ u16 hp;
|
||||
/*0x2A*/ u8 level;
|
||||
/*0x2B*/ u8 friendship;
|
||||
/*0x2C*/ u16 maxHP;
|
||||
/*0x2E*/ u16 item;
|
||||
/*0x30*/ u8 nickname[POKEMON_NAME_LENGTH + 1];
|
||||
/*0x3B*/ u8 ppBonuses;
|
||||
/*0x3C*/ u8 otName[8];
|
||||
/*0x44*/ u32 experience;
|
||||
/*0x48*/ u32 personality;
|
||||
/*0x4C*/ u32 status1;
|
||||
/*0x50*/ u32 status2;
|
||||
/*0x54*/ u32 otId;
|
||||
};
|
||||
|
||||
struct BaseStats
|
||||
{
|
||||
/* 0x00 */ u8 baseHP;
|
||||
/* 0x01 */ u8 baseAttack;
|
||||
/* 0x02 */ u8 baseDefense;
|
||||
/* 0x03 */ u8 baseSpeed;
|
||||
/* 0x04 */ u8 baseSpAttack;
|
||||
/* 0x05 */ u8 baseSpDefense;
|
||||
/* 0x06 */ u8 type1;
|
||||
/* 0x07 */ u8 type2;
|
||||
/* 0x08 */ u8 catchRate;
|
||||
/* 0x09 */ u8 expYield;
|
||||
/* 0x0A */ u16 evYield_HP:2;
|
||||
/* 0x0A */ u16 evYield_Attack:2;
|
||||
/* 0x0A */ u16 evYield_Defense:2;
|
||||
/* 0x0A */ u16 evYield_Speed:2;
|
||||
/* 0x0B */ u16 evYield_SpAttack:2;
|
||||
/* 0x0B */ u16 evYield_SpDefense:2;
|
||||
/* 0x0C */ u16 item1;
|
||||
/* 0x0E */ u16 item2;
|
||||
/* 0x10 */ u8 genderRatio;
|
||||
/* 0x11 */ u8 eggCycles;
|
||||
/* 0x12 */ u8 friendship;
|
||||
/* 0x13 */ u8 growthRate;
|
||||
/* 0x14 */ u8 eggGroup1;
|
||||
/* 0x15 */ u8 eggGroup2;
|
||||
/* 0x16 */ u8 ability1;
|
||||
/* 0x17 */ u8 ability2;
|
||||
/* 0x18 */ u8 safariZoneFleeRate;
|
||||
/* 0x19 */ u8 bodyColor:7;
|
||||
u8 unk19_7:1;
|
||||
/*0x00*/ u8 baseHP;
|
||||
/*0x01*/ u8 baseAttack;
|
||||
/*0x02*/ u8 baseDefense;
|
||||
/*0x03*/ u8 baseSpeed;
|
||||
/*0x04*/ u8 baseSpAttack;
|
||||
/*0x05*/ u8 baseSpDefense;
|
||||
/*0x06*/ u8 type1;
|
||||
/*0x07*/ u8 type2;
|
||||
/*0x08*/ u8 catchRate;
|
||||
/*0x09*/ u8 expYield;
|
||||
/*0x0A*/ u16 evYield_HP:2;
|
||||
/*0x0A*/ u16 evYield_Attack:2;
|
||||
/*0x0A*/ u16 evYield_Defense:2;
|
||||
/*0x0A*/ u16 evYield_Speed:2;
|
||||
/*0x0B*/ u16 evYield_SpAttack:2;
|
||||
/*0x0B*/ u16 evYield_SpDefense:2;
|
||||
/*0x0C*/ u16 item1;
|
||||
/*0x0E*/ u16 item2;
|
||||
/*0x10*/ u8 genderRatio;
|
||||
/*0x11*/ u8 eggCycles;
|
||||
/*0x12*/ u8 friendship;
|
||||
/*0x13*/ u8 growthRate;
|
||||
/*0x14*/ u8 eggGroup1;
|
||||
/*0x15*/ u8 eggGroup2;
|
||||
/*0x16*/ u8 ability1;
|
||||
/*0x17*/ u8 ability2;
|
||||
/*0x18*/ u8 safariZoneFleeRate;
|
||||
/*0x19*/ u8 bodyColor:7;
|
||||
u8 unk19_7:1;
|
||||
};
|
||||
|
||||
struct BattleMove
|
||||
@ -378,10 +378,10 @@ struct BattleMove
|
||||
|
||||
struct PokemonStorage
|
||||
{
|
||||
/* 0x00 */ u8 currentBox;
|
||||
/* 0x01 */ struct BoxPokemon boxes[14][30];
|
||||
u8 boxNames[14][9];
|
||||
u8 unkArray[14];
|
||||
/*0x00*/ u8 currentBox;
|
||||
/*0x01*/ struct BoxPokemon boxes[14][30];
|
||||
u8 boxNames[14][9];
|
||||
u8 unkArray[14];
|
||||
};
|
||||
|
||||
struct Evolution
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
extern const u8 *const gNatureNames[];
|
||||
|
||||
void ShowPokemonSummaryScreen(struct Pokemon *, u8, u8, void (*)(u8), int);
|
||||
void ShowPokemonSummaryScreen(struct Pokemon *, u8, u8, void (*)(void), int);
|
||||
void sub_809D9F0(struct Pokemon *party, u8, u8, void *, u32);
|
||||
void sub_809D9F0(struct Pokemon *, u8, u8, void *, u32);
|
||||
u8 sub_809FA30(void);
|
||||
|
@ -13,13 +13,53 @@ void sub_800C1A8(u8);
|
||||
void sub_800C35C(void);
|
||||
void sub_800C47C(u8);
|
||||
void EmitGetAttributes(u8 a, u8 b, u8 c);
|
||||
void dp01_build_cmdbuf_x01_a_b_0(u8 a, u8 b, u8 c);
|
||||
void EmitSetAttributes(u8 a, u8 b, u8 c, u8 d, u8 *e);
|
||||
void dp01_build_cmdbuf_x04_4_4_4(u8 a);
|
||||
void sub_800C704(u8, u8, u8);
|
||||
void dp01_build_cmdbuf_x06_a(u8 a, u8 b);
|
||||
void dp01_build_cmdbuf_x07_7_7_7(u8 a);
|
||||
void dp01_build_cmdbuf_x08_8_8_8(u8 a);
|
||||
void dp01_build_cmdbuf_x09_9_9_9(u8 a);
|
||||
void EmitFaintAnimation(u8 a);
|
||||
void dp01_build_cmdbuf_x0B_B_B_B(u8 a);
|
||||
void dp01_build_cmdbuf_x0C_C_C_C(u8 a);
|
||||
void dp01_build_cmdbuf_x0D_a(u8 a, u8 b);
|
||||
void EmitMoveAnimation(u8 a, u16 b, u8 c, u16 d, s32 e, u8 f, u8 *g);
|
||||
void EmitPrintString(u8 a, u16 b);
|
||||
void dp01_build_cmdbuf_x12_a_bb(u8 a, u8 b, u16 c);
|
||||
void sub_800CBA4(u8 a, u8 b, u8 c, u8 *d);
|
||||
void sub_800CBE0(u8 a, u8 *b);
|
||||
void dp01_build_cmdbuf_x16_a_b_c_ptr_d_e_f(u8 a, u8 b, u8 c, u8 d, u8 *e);
|
||||
void dp01_build_cmdbuf_x17_17_17_17(u8 a);
|
||||
void EmitHealthBarUpdate(u8 a, s16 b);
|
||||
void EmitExpBarUpdate(u8 a, u8 b, s16 c);
|
||||
void EmitStatusIconUpdate(u8 a, u32 b, u32 c);
|
||||
void EmitStatusAnimation(u8 a, u8 b, u32 c);
|
||||
void EmitStatusXor(u8 a, u8 b);
|
||||
void dp01_build_cmdbuf_x1D_1D_numargs_varargs(u8, u16, u8 *);
|
||||
void dp01_build_cmdbuf_x21_a_bb(u8 a, u8 b, u16 c);
|
||||
void dp01_build_cmdbuf_x22_a_three_bytes(u8 a, u8 b, u8 *c);
|
||||
void dp01_build_cmdbuf_x23_aa_0(u8 a, u16 b);
|
||||
void dp01_build_cmdbuf_x24_aa_0(u8 a, u16 b);
|
||||
void dp01_build_cmdbuf_x25_25_25_25(u8 a);
|
||||
void dp01_build_cmdbuf_x26_a(u8 a, u8 b);
|
||||
void dp01_build_cmdbuf_x27_27_27_27(u8 a);
|
||||
void dp01_build_cmdbuf_x28_28_28_28(u8 a);
|
||||
void EmitHitAnimation(u8 a);
|
||||
void dp01_build_cmdbuf_x2A_2A_2A_2A(u8 a);
|
||||
void EmitEffectivenessSound(u8 a, u16 b);
|
||||
void sub_800D074(u8 a, u16 b);
|
||||
void EmitFaintingCry(u8 a);
|
||||
void EmitBattleIntroSlide(u8 a, u8 b);
|
||||
void dp01_build_cmdbuf_x2F_2F_2F_2F(u8 a);
|
||||
void dp01_build_cmdbuf_x30_TODO(u8 a, u8 *b, u8 c);
|
||||
void dp01_build_cmdbuf_x31_31_31_31(u8 a);
|
||||
void dp01_build_cmdbuf_x32_32_32_32(u8 a);
|
||||
void EmitSpriteInvisibility(u8 a, u8 b);
|
||||
void EmitBattleAnimation(u8 a, u8 b, u16 c);
|
||||
void EmitLinkStandbyMsg(u8 a, u8 b);
|
||||
void EmitResetActionMoveSelection(u8 a, u8 b);
|
||||
void dp01_build_cmdbuf_x37_a(u8 a, u8 b);
|
||||
|
||||
#endif // GUARD_ROM3_H
|
||||
|
@ -121,16 +121,16 @@ enum
|
||||
/*0x73*/ SE_TB_KON,
|
||||
/*0x74*/ SE_TB_KARA,
|
||||
/*0x75*/ SE_BIDORO,
|
||||
SE_W085,
|
||||
SE_W085B,
|
||||
SE_W231,
|
||||
SE_W171,
|
||||
SE_W233,
|
||||
SE_W233B,
|
||||
SE_W145,
|
||||
SE_W145B,
|
||||
SE_W145C,
|
||||
SE_W240,
|
||||
/*0x76*/ SE_W085,
|
||||
/*0x77*/ SE_W085B,
|
||||
/*0x78*/ SE_W231,
|
||||
/*0x79*/ SE_W171,
|
||||
/*0x7A*/ SE_W233,
|
||||
/*0x7B*/ SE_W233B,
|
||||
/*0x7C*/ SE_W145,
|
||||
/*0x7D*/ SE_W145B,
|
||||
/*0x7E*/ SE_W145C,
|
||||
/*0x7F*/ SE_W240,
|
||||
SE_W015,
|
||||
SE_W081,
|
||||
SE_W081B,
|
||||
|
@ -56,9 +56,7 @@ SECTIONS {
|
||||
asm/battle_3.o(.text);
|
||||
asm/battle_4.o(.text);
|
||||
asm/battle_5.o(.text);
|
||||
asm/battle_6.o(.text);
|
||||
src/battle_6.o(.text);
|
||||
asm/battle_6.o(.text_8030464);
|
||||
src/battle_7.o(.text);
|
||||
asm/battle_8.o(.text);
|
||||
asm/battle_9.o(.text);
|
||||
@ -237,7 +235,7 @@ SECTIONS {
|
||||
asm/battle_transition.o(.text);
|
||||
src/battle_811DA74.o(.text);
|
||||
asm/battle_message.o(.text);
|
||||
asm/choose_party.o(.text);
|
||||
src/choose_party.o(.text);
|
||||
asm/cable_car.o(.text);
|
||||
asm/roulette_util.o(.text);
|
||||
asm/cable_car_util.o(.text);
|
||||
@ -258,7 +256,7 @@ SECTIONS {
|
||||
src/roamer.o(.text);
|
||||
asm/battle_tower.o(.text);
|
||||
asm/use_pokeblock.o(.text);
|
||||
asm/battle_anim_8137220.o(.text);
|
||||
src/battle_anim_8137220.o(.text);
|
||||
src/player_pc.o(.text);
|
||||
src/intro.o(.text);
|
||||
src/field_region_map.o(.text);
|
||||
@ -394,6 +392,7 @@ SECTIONS {
|
||||
data/pokemon_menu.o(.rodata);
|
||||
data/option_menu.o(.rodata);
|
||||
src/pokedex.o(.rodata);
|
||||
src/trainer_card.o(.rodata);
|
||||
data/trainer_card.o(.rodata);
|
||||
src/battle_party_menu.o(.rodata);
|
||||
data/pokemon_storage_system.o(.rodata);
|
||||
@ -453,7 +452,7 @@ SECTIONS {
|
||||
data/battle_transition.o(.rodata);
|
||||
data/battle_811DA74.o(.rodata);
|
||||
data/battle_message.o(.rodata);
|
||||
data/choose_party.o(.rodata);
|
||||
src/choose_party.o(.rodata);
|
||||
data/cable_car.o(.rodata);
|
||||
src/save.o(.rodata);
|
||||
data/field_effect_helpers.o(.rodata);
|
||||
|
1465
src/battle_6.c
1465
src/battle_6.c
File diff suppressed because it is too large
Load Diff
@ -35,15 +35,7 @@ struct UnknownStruct3
|
||||
u8 ppBonuses;
|
||||
};
|
||||
|
||||
struct UnknownStruct5
|
||||
{
|
||||
u8 unk0_0:7;
|
||||
u8 unk0_7:1;
|
||||
};
|
||||
|
||||
extern u16 gBattleTypeFlags;
|
||||
|
||||
extern struct UnknownStruct5 gUnknown_020238C8;
|
||||
extern u8 gDisplayedStringBattle[];
|
||||
extern u8 gBattleBufferA[][0x200];
|
||||
extern u8 gActiveBank;
|
||||
@ -433,6 +425,7 @@ void LinkPartnerHandleGetAttributes(void)
|
||||
LinkPartnerBufferExecCompleted();
|
||||
}
|
||||
|
||||
// Duplicate of dp01_getattr_by_ch1_for_player_pokemon_
|
||||
u32 dp01_getattr_by_ch1_for_player_pokemon(u8 a, u8 *buffer)
|
||||
{
|
||||
struct BattlePokemon battlePokemon;
|
||||
@ -765,6 +758,7 @@ void LinkPartnerHandleSetAttributes(void)
|
||||
LinkPartnerBufferExecCompleted();
|
||||
}
|
||||
|
||||
// Duplicate of dp01_setattr_by_ch1_for_player_pokemon
|
||||
void sub_811EC68(u8 a)
|
||||
{
|
||||
struct BattlePokemon *battlePokemon = (struct BattlePokemon *)&gBattleBufferA[gActiveBank][3];
|
||||
|
1486
src/battle_anim_8137220.c
Normal file
1486
src/battle_anim_8137220.c
Normal file
File diff suppressed because it is too large
Load Diff
@ -18,30 +18,43 @@
|
||||
#include "task.h"
|
||||
#include "text.h"
|
||||
|
||||
#define DATA_COUNT (6)
|
||||
|
||||
extern u8 ewram[];
|
||||
|
||||
struct Unk201B000
|
||||
{
|
||||
//u8 filler0[0x260];
|
||||
struct Pokemon unk0[6];
|
||||
u8 filler258[1];
|
||||
u8 unk259;
|
||||
u8 filler25A[6];
|
||||
u8 unk260;
|
||||
u8 unk261;
|
||||
u8 filler262[2];
|
||||
s16 unk264[DATA_COUNT * 2]; // This may be a union
|
||||
u8 filler27C[2];
|
||||
s16 unk27E;
|
||||
s16 unk280;
|
||||
s16 unk282;
|
||||
};
|
||||
|
||||
#define ewram1B000 (*(struct Unk201B000 *)(ewram + 0x1B000))
|
||||
#define UNK_201606C_ARRAY (ewram + 0x1606C) // lazy define but whatever.
|
||||
|
||||
extern u8 IsLinkDoubleBattle(void);
|
||||
extern void TryCreatePartyMenuMonIcon(u8, u8, struct Pokemon *);
|
||||
extern void LoadHeldItemIconGraphics(void);
|
||||
extern void CreateHeldItemIcons_806DC34();
|
||||
extern u8 sub_806BD58(u8, u8);
|
||||
extern void PartyMenuPrintMonsLevelOrStatus(void);
|
||||
extern void PrintPartyMenuMonNicknames(void);
|
||||
extern void PartyMenuTryPrintMonsHP(void);
|
||||
extern void nullsub_13(void);
|
||||
extern void PartyMenuDrawHPBars(void);
|
||||
extern u8 sub_806B58C(u8);
|
||||
extern u8 GetItemEffectType();
|
||||
extern void sub_806E750(u8, const struct PartyPopupMenu *, const struct PartyMenuItem *, int);
|
||||
extern u16 sub_806BD80();
|
||||
extern u8 sub_806CA38();
|
||||
extern void sub_806D5A4(void);
|
||||
extern void sub_802E414(void);
|
||||
extern void sub_80A6DCC(void);
|
||||
extern void sub_806AF4C();
|
||||
extern u8 sub_80F9344(void);
|
||||
extern u8 sub_806B124(void);
|
||||
extern void sub_806C994();
|
||||
extern void sub_806BF74();
|
||||
extern void sub_806AEDC(void);
|
||||
extern TaskFunc PartyMenuGetPopupMenuFunc(u8, const struct PartyPopupMenu *, const struct PartyMenuItem *, u8);
|
||||
extern void sub_806E7D0(u8, const struct PartyPopupMenu *);
|
||||
extern u8 *sub_8040D08();
|
||||
extern void sub_8040B8C(void);
|
||||
extern void sub_806E6F0();
|
||||
extern void sub_806D538();
|
||||
extern void nullsub_14();
|
||||
extern void OpenPartyMenu();
|
||||
extern u8 sub_803FBBC(void);
|
||||
|
||||
extern u16 gScriptItemId;
|
||||
extern u8 gPlayerPartyCount;
|
||||
extern u8 gNoOfAllBanks;
|
||||
@ -562,7 +575,7 @@ static void Task_8095330(u8 taskId)
|
||||
}
|
||||
}
|
||||
|
||||
static void Task_809535C(u8 taskId)
|
||||
static void Task_809535C(void)
|
||||
{
|
||||
gPaletteFade.bufferTransferDisabled = TRUE;
|
||||
sub_806AF4C(1, 0xFF, SetUpBattlePokemonMenu, 5);
|
||||
|
1071
src/choose_party.c
Normal file
1071
src/choose_party.c
Normal file
File diff suppressed because it is too large
Load Diff
@ -23,6 +23,14 @@
|
||||
#include "string_util.h"
|
||||
#include "strings.h"
|
||||
#include "task.h"
|
||||
#include "sprite.h"
|
||||
#include "palette.h"
|
||||
#include "event_data.h"
|
||||
#include "main.h"
|
||||
#include "item.h"
|
||||
#include "battle_interface.h"
|
||||
#include "species.h"
|
||||
#include "party_menu.h"
|
||||
|
||||
#define DATA_COUNT (6)
|
||||
|
||||
@ -33,19 +41,6 @@ struct Unk2001000
|
||||
u8 unk2;
|
||||
};
|
||||
|
||||
struct Unk201B000
|
||||
{
|
||||
u8 filler0[0x260];
|
||||
u8 unk260;
|
||||
u8 unk261;
|
||||
u8 filler262[2];
|
||||
s16 unk264[DATA_COUNT * 2]; // This may be a union
|
||||
u8 filler27C[2];
|
||||
s16 unk27E;
|
||||
s16 unk280;
|
||||
s16 unk282;
|
||||
};
|
||||
|
||||
struct Unk201C000
|
||||
{
|
||||
/*0x00*/ struct Pokemon *pokemon;
|
||||
@ -74,7 +69,6 @@ struct UnknownStruct5
|
||||
|
||||
extern u8 ewram[];
|
||||
#define ewram01000 (*(struct Unk2001000 *)(ewram + 0x01000))
|
||||
#define ewram1B000 (*(struct Unk201B000 *)(ewram + 0x1B000))
|
||||
#define ewram1C000 (*(struct Unk201C000 *)(ewram + 0x1C000))
|
||||
#define ewram1F000 (*(struct Unk201F000 *)(ewram + 0x1F000))
|
||||
|
||||
|
@ -31,7 +31,7 @@ extern struct SpriteTemplate gUnknown_02024E8C;
|
||||
extern u8 gContestPlayerMonIndex;
|
||||
extern u8 gIsLinkContest;
|
||||
extern u8 gPlayerPartyCount;
|
||||
extern u8 gBufferedMoves[];
|
||||
extern u8 gSelectedOrderFromParty[];
|
||||
|
||||
extern u16 gSpecialVar_0x8004;
|
||||
extern u16 gSpecialVar_0x8005;
|
||||
@ -653,7 +653,7 @@ void sub_80C5568(void)
|
||||
|
||||
void sub_80C5580(void)
|
||||
{
|
||||
u8 var = gBufferedMoves[0];
|
||||
u8 var = gSelectedOrderFromParty[0];
|
||||
|
||||
switch(var)
|
||||
{
|
||||
@ -676,7 +676,7 @@ void ChooseBattleTowerPlayerParty(void)
|
||||
|
||||
void SetBattleTowerPlayerParty(void)
|
||||
{
|
||||
u8 var = gBufferedMoves[0];
|
||||
u8 var = gSelectedOrderFromParty[0];
|
||||
|
||||
switch(var)
|
||||
{
|
||||
@ -702,8 +702,8 @@ void ReducePlayerPartyToThree(void)
|
||||
|
||||
// copy the selected pokemon according to the order.
|
||||
for(i = 0; i < 3; i++)
|
||||
if(gBufferedMoves[i]) // as long as the order keeps going (did the player select 1 mon? 2? 3?), do not stop
|
||||
party[i] = gPlayerParty[gBufferedMoves[i] - 1]; // index is 0 based, not literal
|
||||
if(gSelectedOrderFromParty[i]) // as long as the order keeps going (did the player select 1 mon? 2? 3?), do not stop
|
||||
party[i] = gPlayerParty[gSelectedOrderFromParty[i] - 1]; // index is 0 based, not literal
|
||||
|
||||
// delete the last 3 pokemon
|
||||
CpuFill32(0, gPlayerParty, sizeof gPlayerParty);
|
||||
|
@ -3,6 +3,7 @@
|
||||
#include "choose_party.h"
|
||||
#include "contest.h"
|
||||
#include "data2.h"
|
||||
#include "party_menu.h"
|
||||
#include "field_fadetransition.h"
|
||||
#include "palette.h"
|
||||
#include "party_menu.h"
|
||||
@ -16,6 +17,8 @@
|
||||
#include "task.h"
|
||||
#include "text.h"
|
||||
|
||||
|
||||
|
||||
extern u8 gPlayerPartyCount;
|
||||
extern u16 gSpecialVar_0x8004;
|
||||
extern u16 gSpecialVar_0x8005;
|
||||
|
@ -928,7 +928,7 @@ gUnknown_0203926A: @ 203926A
|
||||
gAbilitiesPerBank: @ 203926C
|
||||
.space 0x4
|
||||
|
||||
gBufferedMoves: @ 2039270
|
||||
gSelectedOrderFromParty: @ 2039270
|
||||
.space 0x4
|
||||
|
||||
gUnknown_02039274: @ 2039274
|
||||
|
Loading…
x
Reference in New Issue
Block a user