fix style issues

This commit is contained in:
Rainchus 2020-08-12 16:13:09 -05:00
parent f1319a3389
commit 13c32f2bf3
5 changed files with 29 additions and 31 deletions

View File

@ -17,7 +17,8 @@ typedef struct {
/* 0x06C */ char unk_6C[0x4];
/* 0x070 */ s8 unk_70;
/* 0x071 */ s8 demoState;
/* 0x072 */ char unk_72[3];
/* 0x072 */ s8 unk_72;
/* 0x073 */ char unk_73[2];
/* 0x075 */ s8 unk_75;
/* 0x076 */ char unk_76[3];
/* 0x079 */ s8 unk_79;
@ -40,11 +41,10 @@ typedef struct {
/* 0x0AB */ char unk_AB[1];
/* 0x0AC */ s8 unk_AC;
/* 0x0AD */ char unk_AD[0x09];
/* 0x0B6 */ s16 fade_status;
/* 0x0B8 */ s16 boot_logos_unk1;
/* 0x0BA */ s16 boot_logos_unk2;
/* 0x0BC */ s16 boot_logos_unk3;
/* 0x0B6 */ s16 boot_alpha;
/* 0x0B8 */ s16 boot_blue;
/* 0x0BA */ s16 boot_green;
/* 0x0BC */ s16 boot_red;
/* 0x0BE */ char unk_BE[0x76];
/* 0x134 */ u16 unk_134;
/* 0x136 */ char unk_136[0x6];

View File

@ -17,6 +17,8 @@ s32 func_80055464(s32, s32);
s32 func_800554A4(s32, s32);
s32 func_800554E8(s32, s32);
s32 func_800555E4(s32);
void func_80137D88(s32, f32);
void func_80137E10(s32, u8, u8, u8);
s32 play_sound_at_position(s32 soundID, s32 value2, f32 posX, f32 posY, f32 posZ);
s32 set_music_track(s32 musicPlayer, s32 songID, s32 variation, s32 unk, s32 volume);

View File

@ -2,13 +2,13 @@
INCLUDE_ASM(code_cd180_len_38f0, func_80136A80);
INCLUDE_ASM(code_cd180_len_38f0, func_80137D88);
void INCLUDE_ASM(code_cd180_len_38f0, func_80137D88, s32 arg0, f32 arg1);
INCLUDE_ASM(code_cd180_len_38f0, func_80137DA4);
INCLUDE_ASM(code_cd180_len_38f0, func_80137DC0);
INCLUDE_ASM(code_cd180_len_38f0, func_80137E10);
void INCLUDE_ASM(code_cd180_len_38f0, func_80137E10, s32 arg0, u8 arg1, u8 arg2, u8 arg3);
INCLUDE_ASM(code_cd180_len_38f0, func_80137E4C);

View File

@ -49,7 +49,7 @@ u16 read_background_size(bg_header *bg) {
u16 set_background_size(s16 startX, s16 startY, s16 sizeX, s16 sizeY) {
game_status* gameStatus = *gGameStatusPtr;
gameStatus->unk_148 = gameStatus->unk_148 & 0xFFFE;
gameStatus->unk_148 &= ~1;
gameStatus->unk_14E = startX;
gameStatus->unk_150 = startY;
gameStatus->unk_14A = sizeX;
@ -60,7 +60,7 @@ u16 set_background_size(s16 startX, s16 startY, s16 sizeX, s16 sizeY) {
s32 func_80145E98(s32 arg0, s32 arg1, s32 arg2) {
s32 temp_lo;
temp_lo = (arg1 - (arg0 & 0xFFFF)) * arg2;
temp_lo = (arg1 - (u16)(arg0)) * arg2;
if (temp_lo < 0) {
temp_lo = temp_lo + 0xFF;
}

View File

@ -1,27 +1,26 @@
#include "common.h"
void func_800337D0(s16 new_fade_status) {
void func_800337D0(s16 new_alpha) {
game_status* gameStatus = *gGameStatusPtr;
gameStatus->fade_status = new_fade_status;
gameStatus->boot_alpha = new_alpha;
return;
}
void func_800337E0(s16 arg0) {
game_status* gameStatus = *gGameStatusPtr;
gameStatus->boot_logos_unk3 = arg0;
gameStatus->boot_logos_unk2 = arg0;
gameStatus->boot_logos_unk1 = arg0;
gameStatus->boot_red = arg0;
gameStatus->boot_green = arg0;
gameStatus->boot_blue = arg0;
}
s16 func_800337F8(subtract_val) {
game_status* gameStatus = *gGameStatusPtr;
if (gameStatus->fade_status != 0){
gameStatus->fade_status -= subtract_val;
if (gameStatus->fade_status << 0x10 < 0){
gameStatus->fade_status = 0;
if (gameStatus->boot_alpha != 0) {
gameStatus->boot_alpha -= subtract_val;
if (gameStatus->boot_alpha << 0x10 < 0){
gameStatus->boot_alpha = 0;
}
}
else {
} else {
return 1;
}
return 0;
@ -29,25 +28,22 @@ s16 func_800337F8(subtract_val) {
s16 func_80033830(add_val) {
game_status* gameStatus = *gGameStatusPtr;
if (gameStatus->fade_status != 0xFF){
gameStatus->fade_status += add_val;
if ((gameStatus->fade_status >= 0x100)){
gameStatus->fade_status = 0xFF;
if (gameStatus->boot_alpha != 0xFF) {
gameStatus->boot_alpha += add_val;
if ((gameStatus->boot_alpha >= 0x100)) {
gameStatus->boot_alpha = 0xFF;
}
}
else {
} else {
return 1;
}
return 0;
}
void func_80137D88(s32, f32);
void func_80137E10(s32, u8, u8, u8);
void func_80033874(void) {
func_80137D88(0, (f32) (*gGameStatusPtr)->fade_status);
func_80137E10(0, (*gGameStatusPtr)->boot_logos_unk1, (*gGameStatusPtr)->boot_logos_unk2, (*gGameStatusPtr)->boot_logos_unk3);
func_80137D88(0, (*gGameStatusPtr)->boot_alpha);
func_80137E10(0, (*gGameStatusPtr)->boot_blue, (*gGameStatusPtr)->boot_green, (*gGameStatusPtr)->boot_red);
return 0;
}