From 9158d035af3ab866c62b7825ad332b74191d5ef2 Mon Sep 17 00:00:00 2001 From: Doesnty Date: Wed, 2 Aug 2017 14:18:39 -0500 Subject: Improve battle_4 --- include/battle.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'include/battle.h') diff --git a/include/battle.h b/include/battle.h index 4b2542017..495432259 100644 --- a/include/battle.h +++ b/include/battle.h @@ -220,12 +220,11 @@ struct BattleStruct /* 0x2000000 */ /*0x16001*/ u8 turnEffectsBank; /*0x16002*/ u8 animTurn; /*0x16003*/ u8 scriptingActive; - /*0x16004*/ u8 wrappedMove1[4]; - /*0x16008*/ u8 wrappedMove2[4]; + /*0x16004*/ u8 wrappedMove[8]; /*0x1600C*/ u8 cmd49StateTracker; /*0x1600D*/ u8 unk1600D; /*0x1600E*/ u8 turncountersTracker; - /*0x1600F*/ u8 cmd23StateTracker; + /*0x1600F*/ u8 atk23StateTracker; /*0x16010*/ u8 moveTarget[4]; /*0x16014*/ u8 unk16014; /*0x16015*/ u8 unk16015; -- cgit v1.2.3 From 9ac913c5270c7cc5fc245c2cce6b9e64e848f7e9 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Wed, 23 Aug 2017 19:36:25 +0200 Subject: start working on reshow battle screen --- include/battle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include/battle.h') diff --git a/include/battle.h b/include/battle.h index 9d8092197..d948dfa7d 100644 --- a/include/battle.h +++ b/include/battle.h @@ -522,10 +522,10 @@ struct Struct2017800 { u8 unk0_0:1; u8 unk0_1:1; - u8 unk0_2:1; + u8 substituteSprite:1; u8 unk0_3:1; u8 unk0_4:1; - u16 unk2; + u16 transformedSpecies; }; struct Struct2017810 -- cgit v1.2.3 From 78027fb38d7a9cd25bbbb765b88915d7b63f4839 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Wed, 23 Aug 2017 23:04:00 +0200 Subject: reshow battle screen is decompiled --- include/battle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/battle.h') diff --git a/include/battle.h b/include/battle.h index d948dfa7d..08ed5cf58 100644 --- a/include/battle.h +++ b/include/battle.h @@ -520,7 +520,7 @@ struct BattleResults struct Struct2017800 { - u8 unk0_0:1; + u8 invisible:1; u8 unk0_1:1; u8 substituteSprite:1; u8 unk0_3:1; -- cgit v1.2.3 From 991cbbffbcdbba6ba71ea9a08a7a28a29377f976 Mon Sep 17 00:00:00 2001 From: camthesaxman Date: Sat, 26 Aug 2017 19:45:45 -0500 Subject: import DizzyEggg's battle controller changes --- include/battle.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'include/battle.h') diff --git a/include/battle.h b/include/battle.h index 08ed5cf58..255e6d0e5 100644 --- a/include/battle.h +++ b/include/battle.h @@ -689,17 +689,17 @@ extern u8 gBattleTextBuff1[]; //function declarations of buffer emits void EmitGetAttributes(u8 buffID, u8 request, u8 c); //0x0 -void dp01_build_cmdbuf_x01_a_b_0(u8 a, u8 b, u8 c); //0x1 +void Emitcmd1(u8 a, u8 b, u8 c); //0x1 void EmitSetAttributes(u8 a, u8 request, u8 c, u8 bytes, void *data); //0x2 -void EmitSwitchInAnim(u8 a, u8 b, u8 c); //0x5 +void EmitSendOutPoke(u8 a, u8 b, u8 c); //0x5 void EmitReturnPokeToBall(u8 a, u8 b); //0x6 void EmitTrainerSlide(u8 a); //0x8 -void EmitFaintAnimation(u8 a); //0xA -void EmitBallThrowAnim(u8 a, u8 shakes); //0xD +void Emitcmd10(u8 a); //0xA +void EmitBallThrow(u8 a, u8 shakes); //0xD //void EmitMoveAnimation(u8 a, u16 move, u8 turn, u16 power, s32 dmg, u8 happiness, void *disable_struct); //0xF void EmitPrintString(u8 a, u16 stringID); //0x10 //void EmitPrintStringPlayerOnly(u8 a, u16 stringID); //0x11 -void EmitChoosePokemon(u8 a, u8 b, u8 c, u8 d, u8 *e); //0x16 +void Emitcmd22(u8 a, u8 b, u8 c, u8 d, u8 *e); //0x16 //void EmitHealthBarUpdate(u8 a, u16 b); //0x18; Had to declare the second arg as u16 because s16 wont match in atk0b //void EmitExpBarUpdate(u8 a, u8 b, u16 c); //0x19 void EmitStatusIconUpdate(u8 a, u32 b, u32 c); //0x1A @@ -707,15 +707,15 @@ void EmitStatusAnimation(u8 a, u8 b, u32 c); //0x1B void EmitStatusXor(u8 a, u8 b); //0x1C void EmitHitAnimation(u8 a); //0x29 void EmitEffectivenessSound(u8 a, u16 sound); //0x2B -void EmitPlaySound(u8 a, u16 sound); //0x2C +void Emitcmd44(u8 a, u16 sound); //0x2C void EmitFaintingCry(u8 a); //0x2D -void EmitBattleIntroSlide(u8 a, u8 b); //0x2E -void dp01_build_cmdbuf_x30_TODO(u8 a, u8 *b, u8 c); //0x30 -void dp01_build_cmdbuf_x31_31_31_31(u8 a); //0x31 +void EmitIntroSlide(u8 a, u8 b); //0x2E +void Emitcmd48(u8 a, u8 *b, u8 c); //0x30 +void Emitcmd49(u8 a); //0x31 void EmitSpriteInvisibility(u8 a, u8 b); //0x33 void EmitBattleAnimation(u8 a, u8 b, u16 c); //0x34 void EmitResetActionMoveSelection(u8 a, u8 b); //0x36 -void dp01_build_cmdbuf_x37_a(u8 a, u8 b); //0x37 +void Emitcmd55(u8 a, u8 b); //0x37 #define REQUEST_ALL_BATTLE 0x0 #define REQUEST_SPECIES_BATTLE 0x1 -- cgit v1.2.3 From 2f7e3b3f6bfa62d60adb6f24f8a59f93987dca3d Mon Sep 17 00:00:00 2001 From: camthesaxman Date: Sun, 27 Aug 2017 11:14:39 -0500 Subject: Emitcmd22 -> EmitChoosePokemon --- include/battle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/battle.h') diff --git a/include/battle.h b/include/battle.h index 255e6d0e5..72211f50f 100644 --- a/include/battle.h +++ b/include/battle.h @@ -699,7 +699,7 @@ void EmitBallThrow(u8 a, u8 shakes); //0xD //void EmitMoveAnimation(u8 a, u16 move, u8 turn, u16 power, s32 dmg, u8 happiness, void *disable_struct); //0xF void EmitPrintString(u8 a, u16 stringID); //0x10 //void EmitPrintStringPlayerOnly(u8 a, u16 stringID); //0x11 -void Emitcmd22(u8 a, u8 b, u8 c, u8 d, u8 *e); //0x16 +void EmitChoosePokemon(u8 a, u8 b, u8 c, u8 d, u8 *e); //0x16 //void EmitHealthBarUpdate(u8 a, u16 b); //0x18; Had to declare the second arg as u16 because s16 wont match in atk0b //void EmitExpBarUpdate(u8 a, u8 b, u16 c); //0x19 void EmitStatusIconUpdate(u8 a, u32 b, u32 c); //0x1A -- cgit v1.2.3 From a185f8a26dc5e5a04908c272ab54bede7af8a10c Mon Sep 17 00:00:00 2001 From: camthesaxman Date: Tue, 12 Sep 2017 16:53:04 -0500 Subject: lots more relabeling --- include/battle.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'include/battle.h') diff --git a/include/battle.h b/include/battle.h index 72211f50f..47cb7cf8e 100644 --- a/include/battle.h +++ b/include/battle.h @@ -173,6 +173,20 @@ #define WEATHER_SUN_ANY ((WEATHER_SUN_TEMPORARY | WEATHER_SUN_PERMANENT)) #define WEATHER_HAIL (1 << 7) +enum +{ + BATTLE_TERRAIN_GRASS, + BATTLE_TERRAIN_LONG_GRASS, + BATTLE_TERRAIN_SAND, + BATTLE_TERRAIN_UNDERWATER, + BATTLE_TERRAIN_WATER, + BATTLE_TERRAIN_POND, + BATTLE_TERRAIN_MOUNTAIN, + BATTLE_TERRAIN_CAVE, + BATTLE_TERRAIN_BUILDING, + BATTLE_TERRAIN_PLAIN, +}; + // needed to match the hack that is get_item, thanks cam, someone else clean this up later. extern u8 unk_2000000[]; -- cgit v1.2.3