mirror of
https://github.com/jiangzhengwenjz/katam.git
synced 2024-11-27 07:00:41 +00:00
changes
This commit is contained in:
parent
5a1d596940
commit
ad3aaaeb89
@ -4,11 +4,12 @@
|
||||
#include "global.h"
|
||||
|
||||
#define PlaySfx(ptr, num) \
|
||||
if (gUnk_02020EE0[gUnk_0203AD3C].unk60 == ptr->unk60) \
|
||||
({if (gUnk_02020EE0[gUnk_0203AD3C].unk60 == ptr->unk60) \
|
||||
if ((ptr->unk0 != 0) || (ptr->unk56 == gUnk_0203AD3C)) \
|
||||
if (gUnk_08D60FA4[gSongTable[num].ms]->unk4 < 0 || gUnk_08D60FA4[gSongTable[num].ms]->unk9 <= gSongTable[num].header->priority) \
|
||||
if (gSongTable[num].ms == 0 || !(gUnk_0203AD10 & 0x100)) \
|
||||
m4aSongNumStart(num);
|
||||
m4aSongNumStart(num); \
|
||||
})
|
||||
|
||||
struct Unk_02023720 {
|
||||
struct Unk_02023720 *unk00;
|
||||
|
@ -1,5 +1,5 @@
|
||||
#ifndef GUARD_WADDLE_DEE
|
||||
#define GUARD_WADDLE_DEE
|
||||
#ifndef GUARD_WADDLE_DEE_H
|
||||
#define GUARD_WADDLE_DEE_H
|
||||
|
||||
#include "data.h"
|
||||
#include "functions.h"
|
||||
|
16
src/bonus.c
16
src/bonus.c
@ -68,7 +68,7 @@ void sub_08122CEC(struct Object2* arg0) {
|
||||
arg0->flags |= 0x200;
|
||||
if (r8->unkD4 == 0x69) {
|
||||
if (--arg0->unk4 << 0x10 == 0) {
|
||||
PlaySfx(arg0, 0xa6)
|
||||
PlaySfx(arg0, 0xa6);
|
||||
sub_08123814(arg0);
|
||||
arg0->xspeed = (Rand16() & 0xff) - 0x60;
|
||||
arg0->yspeed = (Rand16() & 0xff) + 0x1a0;
|
||||
@ -87,7 +87,7 @@ void sub_08122CEC(struct Object2* arg0) {
|
||||
void sub_08122E08(struct Object2* arg0) {
|
||||
arg0->flags |= 0x200;
|
||||
if (--arg0->unk4 << 0x10 == 0) {
|
||||
PlaySfx(arg0, 0xa6)
|
||||
PlaySfx(arg0, 0xa6);
|
||||
arg0->yspeed = 0x240;
|
||||
sub_0808AE30(arg0, 0, 0x2B4, 0);
|
||||
sub_0809513C(arg0, 0, 0);
|
||||
@ -118,7 +118,7 @@ void sub_08122ED4(struct Object2* arg0) {
|
||||
if (arg0->flags & 0x40000) {
|
||||
struct Kirby* kirby = arg0->unk6C;
|
||||
if (kirby->unk0 == 0) {
|
||||
if(sub_0803925C(arg0, kirby) != 0) {
|
||||
if (sub_0803925C(arg0, kirby) != 0) {
|
||||
if (kirby->unk56 < gUnk_0203AD30) {
|
||||
BonusSetFunc(arg0);
|
||||
}
|
||||
@ -151,7 +151,7 @@ void BonusSetFunc(struct Object2* arg0) {
|
||||
if (arg0->unkB0->unk2 != 0x1f00) {
|
||||
sub_080029F4(gUnk_02023530[arg0->unk56].unk65E, 1);
|
||||
}
|
||||
PlaySfx(arg0, 0x1f4)
|
||||
PlaySfx(arg0, 0x1f4);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -171,7 +171,7 @@ void BonusAddHpOrBattery(struct Object2* arg0) {
|
||||
else {
|
||||
r8 = 1;
|
||||
kirby->hp++;
|
||||
PlaySfx(kirby, 0x1f6)
|
||||
PlaySfx(kirby, 0x1f6);
|
||||
}
|
||||
|
||||
if (!r8 || arg0->unk80 == 0) {
|
||||
@ -188,7 +188,7 @@ void BonusAddHpOrBattery(struct Object2* arg0) {
|
||||
else {
|
||||
if (kirby->battery <= 2) {
|
||||
kirby->battery++;
|
||||
PlaySfx(kirby, 0x1f6)
|
||||
PlaySfx(kirby, 0x1f6);
|
||||
}
|
||||
arg0->unk80 = 0;
|
||||
arg0->flags |= 0x1000;
|
||||
@ -263,7 +263,7 @@ void BonusAddLives(struct Object2* arg0) {
|
||||
}
|
||||
else {
|
||||
kirby->lives++;
|
||||
PlaySfx(kirby, 0x1f5)
|
||||
PlaySfx(kirby, 0x1f5);
|
||||
}
|
||||
arg0->flags |= 0x1000;
|
||||
arg0->unk80 = 0;
|
||||
@ -449,7 +449,7 @@ void sub_0812385C(struct Object2* arg0) {
|
||||
if (arg0->flags & 0x40000) {
|
||||
struct Kirby* kirby = arg0->unk6C;
|
||||
if (kirby->unk0 == 0) {
|
||||
if(sub_0803925C(arg0, kirby) != 0) {
|
||||
if (sub_0803925C(arg0, kirby) != 0) {
|
||||
if (kirby->unk56 < gUnk_0203AD30) {
|
||||
BonusSetFunc(arg0);
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ struct Object2* CreateWaddleDee(struct Object* arg0, u8 arg1) {
|
||||
sub_080A42B0(obj);
|
||||
}
|
||||
else {
|
||||
switch(arg0->unkE) {
|
||||
switch (arg0->unkE) {
|
||||
default:
|
||||
case 0:
|
||||
sub_080A3E58(obj);
|
||||
@ -40,7 +40,7 @@ struct Object2* CreateWaddleDee(struct Object* arg0, u8 arg1) {
|
||||
|
||||
void sub_080A3CF0(struct Object2* arg0) {
|
||||
arg0->unk84 = 0;
|
||||
switch(arg0->unkB0->unkE) {
|
||||
switch (arg0->unkB0->unkE) {
|
||||
case 1:
|
||||
sub_080A3EC4(arg0);
|
||||
break;
|
||||
@ -109,7 +109,7 @@ void sub_080A3D8C(struct Object2* arg0) {
|
||||
|
||||
void sub_080A3E58(struct Object2* arg0) {
|
||||
sub_0809F7D8(arg0, 0, sub_080A4454);
|
||||
switch(arg0->unk87) {
|
||||
switch (arg0->unk87) {
|
||||
case 0:
|
||||
arg0->xspeed = 0x80;
|
||||
break;
|
||||
@ -130,7 +130,7 @@ void sub_080A3E58(struct Object2* arg0) {
|
||||
|
||||
void sub_080A3EC4(struct Object2* arg0) {
|
||||
sub_0809F7D8(arg0, 0, sub_080A3F30);
|
||||
switch(arg0->unk87) {
|
||||
switch (arg0->unk87) {
|
||||
case 0:
|
||||
arg0->xspeed = 0x80;
|
||||
break;
|
||||
@ -156,7 +156,7 @@ void sub_080A3F30(struct Object2* arg0) {
|
||||
arg0->xspeed = -arg0->xspeed;
|
||||
arg0->unk4 = 0;
|
||||
}
|
||||
switch(arg0->unk87) {
|
||||
switch (arg0->unk87) {
|
||||
case 0:
|
||||
if (arg0->unk4 > 0xc0) {
|
||||
arg0->flags ^= 1;
|
||||
@ -192,7 +192,7 @@ void sub_080A3F30(struct Object2* arg0) {
|
||||
void sub_080A3FD4(struct Object2* arg0) {
|
||||
sub_0809F7D8(arg0, 0, sub_080A4044);
|
||||
arg0->unk4 = 0x64;
|
||||
switch(arg0->unk87) {
|
||||
switch (arg0->unk87) {
|
||||
case 0:
|
||||
arg0->xspeed = 0x80;
|
||||
break;
|
||||
@ -237,7 +237,7 @@ void sub_080A4044(struct Object2* arg0) {
|
||||
void sub_080A40F4(struct Object2* arg0) {
|
||||
sub_0809F7D8(arg0, 2, sub_080A4484);
|
||||
arg0->yspeed = 0x280;
|
||||
switch(arg0->unk87) {
|
||||
switch (arg0->unk87) {
|
||||
case 0:
|
||||
arg0->xspeed = 0x80;
|
||||
break;
|
||||
@ -254,7 +254,7 @@ void sub_080A40F4(struct Object2* arg0) {
|
||||
if (arg0->flags & 1) {
|
||||
arg0->xspeed = -arg0->xspeed;
|
||||
}
|
||||
PlaySfx(arg0, 0x145)
|
||||
PlaySfx(arg0, 0x145);
|
||||
}
|
||||
|
||||
void sub_080A41F4(struct Object2* arg0) {
|
||||
@ -289,7 +289,7 @@ void sub_080A41F4(struct Object2* arg0) {
|
||||
|
||||
void sub_080A42B0(struct Object2* arg0) {
|
||||
sub_0809F7D8(arg0, 0, sub_080A431C);
|
||||
switch(arg0->unk87) {
|
||||
switch (arg0->unk87) {
|
||||
case 0:
|
||||
arg0->xspeed = 0x80;
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user