diff options
author | GriffinR <griffin.g.richards@gmail.com> | 2021-10-04 10:21:03 -0400 |
---|---|---|
committer | GriffinR <griffin.g.richards@gmail.com> | 2021-10-08 16:39:46 -0400 |
commit | 31b501e7eb6ba15602dd13f6a2d728fca9f04ca5 (patch) | |
tree | bbdeb215ee3e628a4c343d2e2c887e4efe5bcb63 /src/battle_bg.c | |
parent | e26f9d10d7bebee5ea512fc4729ce6adafec66a0 (diff) |
Start misc battle documentation
Diffstat (limited to 'src/battle_bg.c')
-rw-r--r-- | src/battle_bg.c | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/src/battle_bg.c b/src/battle_bg.c index 0ad126509..886a3d107 100644 --- a/src/battle_bg.c +++ b/src/battle_bg.c @@ -594,8 +594,8 @@ static const struct WindowTemplate gBattleArenaWindowTemplates[] = const struct WindowTemplate * const gBattleWindowTemplates[] = { - gStandardBattleWindowTemplates, - gBattleArenaWindowTemplates, + [B_WIN_TYPE_NORMAL] = gStandardBattleWindowTemplates, + [B_WIN_TYPE_ARENA] = gBattleArenaWindowTemplates, }; static const struct BattleBackground gBattleTerrainTable[] = @@ -691,20 +691,19 @@ static const struct BattleBackground gBattleTerrainTable[] = }, }; -static void sub_8035648(void); +static void CB2_UnusedBattleInit(void); -// Unused -static void sub_8035608(void) +static void UnusedBattleInit(void) { u8 spriteId; ResetSpriteData(); - spriteId = CreateSprite(&gUnknown_0831AC88, 0, 0, 0); + spriteId = CreateSprite(&gUnusedBattleInitSprite, 0, 0, 0); gSprites[spriteId].invisible = TRUE; - SetMainCallback2(sub_8035648); + SetMainCallback2(CB2_UnusedBattleInit); } -static void sub_8035648(void) +static void CB2_UnusedBattleInit(void) { AnimateSprites(); BuildOamBuffer(); @@ -717,13 +716,13 @@ void BattleInitBgsAndWindows(void) if (gBattleTypeFlags & BATTLE_TYPE_ARENA) { - gBattleScripting.windowsType = 1; - SetBgTilemapBuffer(1, gUnknown_02023060); - SetBgTilemapBuffer(2, gUnknown_02023060); + gBattleScripting.windowsType = B_WIN_TYPE_ARENA; + SetBgTilemapBuffer(1, gBattleAnimBgTilemapBuffer); + SetBgTilemapBuffer(2, gBattleAnimBgTilemapBuffer); } else { - gBattleScripting.windowsType = 0; + gBattleScripting.windowsType = B_WIN_TYPE_NORMAL; } InitWindows(gBattleWindowTemplates[gBattleScripting.windowsType]); |