document core2/ch/bubble.c

This commit is contained in:
Banjo Kazooie
2023-01-21 20:27:01 -06:00
parent c004632915
commit 36e34b9c1c
4 changed files with 21 additions and 19 deletions

View File

@@ -643,7 +643,7 @@ segments:
- [0xF92D30, c, ch/gameSelect] #DONE - [0xF92D30, c, ch/gameSelect] #DONE
- [0xF94430, c, code_3EAD0] #DONE - [0xF94430, c, code_3EAD0] #DONE
- [0xF94590, c, code_3EC30] #DONE - [0xF94590, c, code_3EC30] #DONE
- [0xF94640, c, code_3ECE0] #DONE - [0xF94640, c, ch/bubble] #DONE
- [0xF94850, c, ch/bigbutt] #DONE - [0xF94850, c, ch/bigbutt] #DONE
- [0xF95A50, c, code_400F0] #DONE - [0xF95A50, c, code_400F0] #DONE
- [0xF96400, c, ch/jiggy] #DONE - [0xF96400, c, ch/jiggy] #DONE
@@ -940,7 +940,7 @@ segments:
- [0x10347A0, .data, ch/gameSelect] - [0x10347A0, .data, ch/gameSelect]
- [0x1034900, .data, code_3EAD0] - [0x1034900, .data, code_3EAD0]
- [0x1034980, .data, code_3EC30] - [0x1034980, .data, code_3EC30]
- [0x10349B0, .data, code_3ECE0] - [0x10349B0, .data, ch/bubble]
- [0x10349E0, .data, ch/bigbutt] - [0x10349E0, .data, ch/bigbutt]
- [0x1034AC0, .data, code_400F0] - [0x1034AC0, .data, code_400F0]
- [0x1034C60, .data, ch/jiggy] - [0x1034C60, .data, ch/jiggy]
@@ -1209,7 +1209,7 @@ segments:
- [0x1044990, .rodata, code_3AE10] - [0x1044990, .rodata, code_3AE10]
- [0x10449A0, .rodata, spawnqueue] - [0x10449A0, .rodata, spawnqueue]
- [0x10449F0, .rodata, ch/gameSelect] - [0x10449F0, .rodata, ch/gameSelect]
- [0x1044B70, .rodata, code_3ECE0] - [0x1044B70, .rodata, ch/bubble]
- [0x1044B80, .rodata, ch/bigbutt] - [0x1044B80, .rodata, ch/bigbutt]
- [0x1044C60, .rodata, code_400F0] - [0x1044C60, .rodata, code_400F0]
- [0x1044CC0, .rodata, ch/jiggy] - [0x1044CC0, .rodata, ch/jiggy]

View File

@@ -3469,6 +3469,8 @@ enum asset_e
ASSET_701_SPRITE_LENS_SHUTTER_MASK, ASSET_701_SPRITE_LENS_SHUTTER_MASK,
ASSET_702_SPRITE_UNKNOWN, ASSET_702_SPRITE_UNKNOWN,
ASSET_704_SPRITE_BUBBLE = 0x704,
ASSET_708_SPRITE_EGG_PROJECTILE = 0x708, ASSET_708_SPRITE_EGG_PROJECTILE = 0x708,
ASSET_70A_SPRITE_BUBBLE_1 = 0x70a, ASSET_70A_SPRITE_BUBBLE_1 = 0x70a,
@@ -3765,9 +3767,9 @@ enum marker_e{
MARKER_67_JUJU = 0x67, MARKER_67_JUJU = 0x67,
MARKER_69_CHUMP_FISH = 0x69, MARKER_69_CHUMP_FISH = 0x69,
MARKER_6A_GLOOP = 0x6A, MARKER_6A_GLOOP,
MARKER_6B_GLOOPBUBBLE,
MARKER_6C_TANKTUP = 0x6C, MARKER_6C_TANKTUP,
MARKER_6D_TANKTUP_LEG, MARKER_6D_TANKTUP_LEG,
MARKER_6E_PINK_EGG_LARGEST, MARKER_6E_PINK_EGG_LARGEST,

View File

@@ -6,18 +6,18 @@ typedef struct {
s32 unk0; s32 unk0;
}ActorLocal_Core2_3ECE0; }ActorLocal_Core2_3ECE0;
void func_802C5DDC(Actor *this); void chBubble_update(Actor *this);
extern void func_802F32C4(s32, f32[3], f32, ActorMarker *, void(*)(f32[3], f32, ActorMarker *)); extern void func_802F32C4(s32, f32[3], f32, ActorMarker *, void(*)(f32[3], f32, ActorMarker *));
/* .data */ /* .data */
ActorInfo D_80365FE0 = { ActorInfo chBubble = {
0x6B, 0xE7, 0x704, MARKER_6B_GLOOPBUBBLE, ACTOR_E7_GLOOP_BUBBLE, ASSET_704_SPRITE_BUBBLE,
0, NULL, func_802C5DDC, func_80326224, func_80325340, 0, NULL, chBubble_update, func_80326224, func_80325340,
0, 0, 0.0f, 0 0, 0, 0.0f, 0
}; };
/* .code */ /* .code */
int func_802C5C70(f32 arg0[3], f32 arg1, ActorMarker *marker){ int __chBubble_func_802C5C70(f32 arg0[3], f32 arg1, ActorMarker *marker){
s32 pad2C; s32 pad2C;
Actor *this = marker_getActor(marker); Actor *this = marker_getActor(marker);
ActorLocal_Core2_3ECE0 *local = (ActorLocal_Core2_3ECE0 *) &this->local; ActorLocal_Core2_3ECE0 *local = (ActorLocal_Core2_3ECE0 *) &this->local;
@@ -38,11 +38,11 @@ int func_802C5C70(f32 arg0[3], f32 arg1, ActorMarker *marker){
return sp1C; return sp1C;
} }
void func_802C5D54(Actor *this){ void __chBubble_freeCallback(Actor *this){
func_8030E988(SFX_C5_TWINKLY_POP, 1.0f, 32000, this->position, 100.0f, 3000.0f); func_8030E988(SFX_C5_TWINKLY_POP, 1.0f, 32000, this->position, 100.0f, 3000.0f);
} }
void func_802C5DA0(ActorMarker *this_marker, ActorMarker *other_marker){ void __chBubble_collisionCallback(ActorMarker *this_marker, ActorMarker *other_marker){
Actor *this = marker_getActor(this_marker); Actor *this = marker_getActor(this_marker);
ActorLocal_Core2_3ECE0 *local = (ActorLocal_Core2_3ECE0 *) &this->local; ActorLocal_Core2_3ECE0 *local = (ActorLocal_Core2_3ECE0 *) &this->local;
local->unk0 = 1; local->unk0 = 1;
@@ -50,12 +50,12 @@ void func_802C5DA0(ActorMarker *this_marker, ActorMarker *other_marker){
} }
void func_802C5DDC(Actor *this){ void chBubble_update(Actor *this){
if(!this->initialized){ if(!this->initialized){
this->initialized = TRUE; this->initialized = TRUE;
marker_setCollisionScripts(this->marker, func_802C5DA0, NULL, NULL); marker_setCollisionScripts(this->marker, __chBubble_collisionCallback, NULL, NULL);
marker_setFreeMethod(this->marker, func_802C5D54); marker_setFreeMethod(this->marker, __chBubble_freeCallback);
func_802F32C4(func_8032994C(), this->position, 200.0f, this->marker, func_802C5C70); func_802F32C4(func_8032994C(), this->position, 200.0f, this->marker, __chBubble_func_802C5C70);
this->unk60 = 10.0f; this->unk60 = 10.0f;
} }
} }

View File

@@ -21,7 +21,7 @@ extern ActorInfo D_80365F00; //banjo.cooking
extern ActorInfo D_80365F60; extern ActorInfo D_80365F60;
extern ActorInfo D_80365F84; //turbotrainers extern ActorInfo D_80365F84; //turbotrainers
extern ActorInfo D_80365FB0; //shrapnel extern ActorInfo D_80365FB0; //shrapnel
extern ActorInfo D_80365FE0; extern ActorInfo chBubble;
extern ActorInfo D_80366090; //bigbutt extern ActorInfo D_80366090; //bigbutt
extern ActorInfo D_803660B4; //brownbull extern ActorInfo D_803660B4; //brownbull
extern ActorInfo D_803662A8; //jiggy extern ActorInfo D_803662A8; //jiggy
@@ -250,7 +250,7 @@ void spawnQueue_reset(void){
spawnableActorList_add(&D_80367A50, actor_new, 0x0000004); //chbadshad spawnableActorList_add(&D_80367A50, actor_new, 0x0000004); //chbadshad
spawnableActorList_add(&D_803685A0, actor_new, 0x0000040); //mumbotoken spawnableActorList_add(&D_803685A0, actor_new, 0x0000040); //mumbotoken
spawnableActorList_add(&D_80367F30, actor_new, 0x0000400); spawnableActorList_add(&D_80367F30, actor_new, 0x0000400);
spawnableActorList_add(&D_80365FE0, actor_new, 0x0000004); spawnableActorList_add(&chBubble, actor_new, 0x0000004);
spawnableActorList_add(&chGloop, actor_new, 0x000008A); //gloop spawnableActorList_add(&chGloop, actor_new, 0x000008A); //gloop
spawnableActorList_add(&D_80366F20, actor_new, 0x0000000); //chshockjump spawnableActorList_add(&D_80366F20, actor_new, 0x0000000); //chshockjump
spawnableActorList_add(&D_80366F44, actor_new, 0x0000000); //flight_pad spawnableActorList_add(&D_80366F44, actor_new, 0x0000000); //flight_pad