Resolving PR review

This commit is contained in:
fieldy101
2020-04-23 10:05:19 +10:00
parent 1bddb1ff39
commit 4c409fa343
5 changed files with 14 additions and 13 deletions
+1 -1
View File
@@ -54,4 +54,4 @@ types_*.taghl
!sound/programmable_wave_samples/*.pcm
_Deparsed_XSubs.pm
porymap.project.cfg
.vscode/*.*
.vscode/*.*
+2 -2
View File
@@ -556,12 +556,12 @@ void sub_80ADAD8(u8 taskId);
void AnimTask_BlendBackground(u8 taskId);
void sub_80AD800(u8 taskId);
// water.s
// water.c
extern const union AnimCmd *const gAnims_WaterMudOrb[];
extern const union AnimCmd *const gAnims_WaterBubble[];
void AnimWaterPulseRing(struct Sprite *sprite);
// smokescreen.s
// smokescreen.c
u8 SmokescreenImpact(s16 x, s16 y, u8 a3);
// battle_anim_utility_funcs.c
-2
View File
@@ -13,8 +13,6 @@ u16 Random2(void);
//Returns a 32-bit pseudorandom number
#define Random32() (Random() | (Random() << 16))
#define ISO_RANDOMIZE2(val)(1103515245 * (val) + 12345)
//Sets the initial seed value of the pseudorandom number generator
void SeedRng(u16 seed);
void SeedRng2(u16 seed);
-1
View File
@@ -1088,7 +1088,6 @@ const u32 gBattleAnimSpritePal_CrossImpact[] = INCBIN_U32("graphics/battle_anims
const u32 gBattleAnimBgImage_Surf[] = INCBIN_U32("graphics/battle_anims/backgrounds/water.4bpp.lz");
const u32 gBattleAnimBgPalette_Surf[] = INCBIN_U32("graphics/battle_anims/backgrounds/water.gbapal.lz");
// TODO Rename and move graphics
const u32 gBattleAnimBgTilemap_SurfOpponent[] = INCBIN_U32("graphics/battle_anims/backgrounds/water_opponent.bin.lz");
const u32 gBattleAnimBgTilemap_SurfPlayer[] = INCBIN_U32("graphics/battle_anims/backgrounds/water_player.bin.lz");
const u32 gBattleAnimBgTilemap_SurfContest[] = INCBIN_U32("graphics/battle_anims/backgrounds/water_contest.bin.lz");
+11 -7
View File
@@ -12,6 +12,8 @@
#include "trig.h"
#include "util.h"
#define ISO_RANDOMIZE2(val)(1103515245 * (val) + 12345)
static void AnimRainDrop(struct Sprite *);
static void AnimRainDrop_Step(struct Sprite *);
static void AnimWaterBubbleProjectile(struct Sprite *);
@@ -87,7 +89,7 @@ const struct SpriteTemplate gRainDropSpriteTemplate =
static const union AffineAnimCmd sAffineAnim_WaterBubbleProjectile[] =
{
AFFINEANIMCMD_FRAME(0xFFFB, 0xFFFB, 0, 10),
AFFINEANIMCMD_FRAME(-0x5, -0x5, 0, 10),
AFFINEANIMCMD_FRAME(0x5, 0x5, 0, 10),
AFFINEANIMCMD_JUMP(0),
};
@@ -259,7 +261,7 @@ static const union AffineAnimCmd sAffineAnim_HydroCannonCharge[] =
{
AFFINEANIMCMD_FRAME(0x3, 0x3, 10, 50),
AFFINEANIMCMD_FRAME(0x0, 0x0, 0, 10),
AFFINEANIMCMD_FRAME(0xFFEC, 0xFFEC, -10, 20),
AFFINEANIMCMD_FRAME(-0x14, -0x14, -10, 20),
AFFINEANIMCMD_END,
};
@@ -411,14 +413,14 @@ static const union AnimCmd *const sAnims_WeatherBallWaterDown[] =
static const union AffineAnimCmd sAffineAnim_WaterPulseRingBubble_0[] =
{
AFFINEANIMCMD_FRAME(0x100, 0x100, 0, 0),
AFFINEANIMCMD_FRAME(0xFFF6, 0xFFF6, 0, 15),
AFFINEANIMCMD_FRAME(-0xA, -0xA, 0, 15),
AFFINEANIMCMD_END,
};
static const union AffineAnimCmd sAffineAnim_WaterPulseRingBubble_1[] =
{
AFFINEANIMCMD_FRAME(0xE0, 0xE0, 0, 0),
AFFINEANIMCMD_FRAME(0xFFF8, 0xFFF8, 0, 15),
AFFINEANIMCMD_FRAME(-0x8, -0x8, 0, 15),
AFFINEANIMCMD_END,
};
@@ -494,11 +496,13 @@ void AnimTask_CreateRaindrops(u8 taskId)
DestroyAnimVisualTask(taskId);
}
static void AnimRainDrop(struct Sprite *sprite) {
static void AnimRainDrop(struct Sprite *sprite)
{
sprite->callback = AnimRainDrop_Step;
}
static void AnimRainDrop_Step(struct Sprite *sprite) {
static void AnimRainDrop_Step(struct Sprite *sprite)
{
if (++sprite->data[0] < 14) // Was 13 in emerald
{
sprite->pos2.x += 1;
@@ -892,7 +896,7 @@ void AnimTask_CreateSurfWave(u8 taskId)
else
{
// Changed from Emerald
LZDecompressVram(gBattleAnimBgTilemap_SurfContest, animBg->bgTilemap);
LZDecompressVram(gBattleAnimBgTilemap_SurfContest, animBg.bgTilemap);
sub_80730C0(animBg.paletteId, animBg.bgTilemap, 0, 1);
}
AnimLoadCompressedBgGfx(animBg.bgId, gBattleAnimBgImage_Surf, animBg.tilesOffset);