define .rodata splits for all core2 files

This commit is contained in:
Banjo Kazooie
2022-09-25 16:30:31 -05:00
parent c3cf6dd913
commit eafea932fa
29 changed files with 112 additions and 179 deletions

View File

@@ -274,8 +274,7 @@ bool func_802CF5E4(Actor *this){
}
void func_802CF610(Actor *this, ParticleEmitter *p_ctrl, f32 position[3]) {
func_8030E6A4(SFX_66_BIRD_AUUGHH, randf2(1.75f, D_803765E4), 15000);
// func_8030E6A4(SFX_66_BIRD_AUUGHH, randf2(1.75f, 1.85f), 15000);
func_8030E6A4(SFX_66_BIRD_AUUGHH, randf2(1.75f, 1.85f), 15000);
particleEmitter_setPosition(p_ctrl, position);
func_802EFA70(p_ctrl, 2);
func_802EF9F8(p_ctrl, 0.5f);

View File

@@ -31,7 +31,7 @@ extern f64 D_80376658;
/* .code */
void func_802D0A00(Actor *this) {
this->unk28 = randf2(1.5f, /*2.3f*/D_80376640);
this->unk28 = randf2(1.5f, 2.3f);
}
#pragma GLOBAL_ASM("asm/nonmatchings/core2/code_49A70/func_802D0A38.s")

View File

@@ -37,15 +37,6 @@ ActorInfo D_80368620 = {
0, 0, 0.0f, 0
};
/* .rodata */
extern f32 D_80377050;
// extern jmptble D_80377054;
extern f64 D_80377080;
extern f32 D_80377088;
extern f64 D_80377090;
extern f64 D_80377098;
/* .bss */
ActorMarker *D_8037E620;
f32 D_8037E628;
@@ -57,10 +48,8 @@ void func_802E0CD0(Actor *this){
this->unk28 = 4.0f;
}
#ifndef NONMATCHING
#pragma GLOBAL_ASM("asm/nonmatchings/core2/code_59D40/func_802E0CE0.s")
#else
void func_802E0CE0(Actor *this) {
ActorLocal_core2_59D40 *local = (ActorLocal_core2_59D40 *)&this->local;
s32 temp_v0;
if (this->unk38_31 != 0) {
@@ -73,7 +62,8 @@ void func_802E0CE0(Actor *this) {
if( !this->unk138_24 ) {
if(temp_v0 < 4) {
if(func_80311480(0xA1B + temp_v0, 0, NULL, NULL, NULL, NULL)){
mapSpecificFlags_setN(8, temp_v0++, 3);
temp_v0++;
mapSpecificFlags_setN(8, temp_v0, 3);
this->unk138_24 = TRUE;
}
}
@@ -82,15 +72,13 @@ void func_802E0CE0(Actor *this) {
func_80328B8C(this, 3, 0.0f, -1);
}
}
#endif
bool func_802E0DC0(f32 arg0[3]){
f32 sp2C[3];
f32 pad0;
player_getPosition(sp2C);
// return (4000000.0f < ml_vec3f_distance_squared(sp2C, arg0))
return (D_80377050 < ml_vec3f_distance_squared(sp2C, arg0))
return (4000000.0f < ml_vec3f_distance_squared(sp2C, arg0))
|| ( (arg0[1] - func_80309724(arg0) < 70.0f) && (func_80309B24(arg0) - arg0[1] < 70.0f));
}
@@ -182,8 +170,8 @@ void func_802E1168(Actor *this) {
f32 sp40;
s32 tmp;
local = (ActorLocal_core2_59D40 *)&this->local;
sp5C = time_getDelta();
local = (ActorLocal_core2_59D40 *)&this->local;
if (!this->initialized) {
this->initialized = TRUE;
@@ -197,14 +185,13 @@ void func_802E1168(Actor *this) {
if(func_802E0DC0(this->position) || ((sp54 != 1) && (sp54 != 2))) {
local->unk8 = MIN(3.5, local->unk8 + sp5C);
if (3.5 == local->unk8) {
if (local->unk8 == 3.5) {
func_802E0EC8();
}
} else {
local->unk8 = 0.0f;
}
if(1);
switch(this->state){
case 1: //802E12C8
if (func_80328BD4(this, 2, 0.0f, 1, 0.03f) != 0) {
@@ -333,10 +320,9 @@ void func_802E17E8(void) {
nodeprop_getPosition(func_80304CAC(0x3CB, sp50), sp50);
}
else{
sp4C = randf2(0.0f, D_80377088);
// temp_f0 = randf2(0.0f, 3.28f);
sp50[0] += D_80377090 * cosf(sp4C);
sp50[2] += D_80377098 * sinf(sp4C);
sp4C = randf2(0.0f, 3.28f);
sp50[0] += 1000.0 * cosf(sp4C);
sp50[2] += 1000.0 * sinf(sp4C);
sp38[0] = sp50[0];
sp38[1] = sp50[1];

View File

@@ -26,10 +26,6 @@ extern s16 D_80368AB8;
extern Gfx D_80368B08[];
extern Struct_core2_6B030_1 D_80368B28[];
/* .rodata */
extern f32 D_803771E0;
extern f32 D_803771E4;
/* .bss */
f32 *D_80380A10;
Mtx D_80380A18;
@@ -64,8 +60,8 @@ void func_802F1FC0(Struct65s *self, Gfx **gfx, Mtx **mtx, Vtx **vtx) {
temp_s5 = (s32) ((f32)self->unk20 * ((1.0f - (self->unk25 / 255.0f)) + ((self->unk25 / 255.0f) - temp_f2)));
func_80251BCC(&D_80380A18);
func_8025235C(&spD0, &spD0);
spD0[0] = (D_803771E0 * spD0[0]) / spD0[2];
spD0[1] = (D_803771E4 * spD0[1]) / spD0[2];
spD0[0] = (-297.0f * spD0[0]) / spD0[2];
spD0[1] = (297.0f * spD0[1]) / spD0[2];
spC4 = (s32) (spD0[0] + (f32) (D_80276588 / 2));
spC0 = (s32) (spD0[1] + (f32) (D_8027658C / 2));
if (spC4 < 0) {

View File

@@ -142,14 +142,14 @@ ParticleEmitter *func_802F3670(s16 arg0[3], f32 arg1, enum asset_e sprite_id){
void func_802F36DC(s16 arg0[3]){
ParticleEmitter *p_emitter = func_802F3670(arg0, 10.0f, ASSET_713_SPRITE_SPARKLE_YELLOW);
particleEmitter_setPositionAndVelocityRanges(p_emitter, &D_80368BD0);
func_802EFB70(p_emitter, D_803771F0, D_803771F0);
func_802EFB70(p_emitter, 0.32f, 0.32f);
particleEmitter_emitN(p_emitter, 10);
}
void func_802F373C(s16 arg0[3]){
ParticleEmitter *p_emitter = func_802F3670(arg0, 10.0f, ASSET_713_SPRITE_SPARKLE_YELLOW);
particleEmitter_setPositionAndVelocityRanges(p_emitter, &D_80368C00);
func_802EFB70(p_emitter, D_803771F4, D_803771F4);
func_802EFB70(p_emitter, 0.32f, 0.32f);
particleEmitter_emitN(p_emitter, 7);
}
@@ -185,7 +185,7 @@ void func_802F38F0(s16 arg0[3]){
-75.0f, 100.0f, -75.0f,
75.0f, 250.0f, 75.0f
);
func_802EFB70(p_emitter, D_803771F8, D_803771F8);
func_802EFB70(p_emitter, 0.3f, 0.3f);
particleEmitter_emitN(p_emitter, 5);
}
@@ -202,7 +202,7 @@ void func_802F39D8(s16 arg0[3]){
-75.0f, 100.0f, -75.0f,
75.0f, 250.0f, 75.0f
);
func_802EFB70(p_emitter, D_803771FC, D_803771FC);
func_802EFB70(p_emitter, 0.3f, 0.3f);
particleEmitter_emitN(p_emitter, 5);
}
@@ -216,7 +216,7 @@ void func_802F3A60(s16 arg0[3]){
void func_802F3AC0(s16 arg0[3]){
ParticleEmitter *p_emitter = func_802F3670(arg0, 10.0f, ASSET_718_SPRITE_SPARKLE_WHITE_2);
particleEmitter_setPositionAndVelocityRanges(p_emitter, &D_80368CC0);
func_802EFB70(p_emitter, D_80377200, D_80377200);
func_802EFB70(p_emitter, 0.4f, 0.4f);
particleEmitter_emitN(p_emitter, 7);
func_802EFEC0(p_emitter, 1.5f, 1.5f);
}
@@ -224,7 +224,7 @@ void func_802F3AC0(s16 arg0[3]){
void func_802F3B3C(s16 arg0[3]){
ParticleEmitter *p_emitter = func_802F3670(arg0, 10.0f, ASSET_713_SPRITE_SPARKLE_YELLOW);
particleEmitter_setPositionAndVelocityRanges(p_emitter, &D_80368CF0);
func_802EFB70(p_emitter, D_80377204, D_80377204);
func_802EFB70(p_emitter, 0.27f, 0.27f);
particleEmitter_emitN(p_emitter, 5);
}

View File

@@ -729,7 +729,7 @@ void _printbuffer_push_new(s32 x, s32 y, u8 * string) {
void print_bold_overlapping(s32 x, s32 y, f32 arg2, u8* string){
_printbuffer_push_new(x, y, string);
if(print_sCurrentPtr){
strcpy(print_sCurrentPtr->fmtString, D_80377240); // strcpy(print_sCurrentPtr->fmtString, "fl");
strcpy(print_sCurrentPtr->fmtString, "fl");
print_sCurrentPtr->unk10 = arg2;
}
}
@@ -737,21 +737,21 @@ void print_bold_overlapping(s32 x, s32 y, f32 arg2, u8* string){
void print_bold_spaced(s32 x, s32 y, u8* string){
_printbuffer_push_new(x, y, string);
if(print_sCurrentPtr){
strcpy(print_sCurrentPtr->fmtString, D_80377244); // strcpy(print_sCurrentPtr->fmtString, "f");
strcpy(print_sCurrentPtr->fmtString, "f");
}
}
void print_dialog(s32 x, s32 y, u8* string){
_printbuffer_push_new(x, y, string);
if(print_sCurrentPtr){
strcpy(print_sCurrentPtr->fmtString, D_80377248); // strcpy(print_sCurrentPtr->fmtString, "elq");
strcpy(print_sCurrentPtr->fmtString, "elq");
}
}
void print_dialog_w_bg(s32 x, s32 y, u8* string){
_printbuffer_push_new(x, y, string);
if(print_sCurrentPtr){
strcpy(print_sCurrentPtr->fmtString, D_8037724C); // strcpy(print_sCurrentPtr->fmtString, "pb");
strcpy(print_sCurrentPtr->fmtString, "pb");
}
}
@@ -760,7 +760,7 @@ void print_dialog_gradient(s32 x, s32 y, u8* string, u8 arg3, u8 arg4){
if(print_sCurrentPtr){
print_sCurrentPtr->unk4 = arg3;
print_sCurrentPtr->unk6 = arg4;
strcpy(print_sCurrentPtr->fmtString, D_80377250); // strcpy(print_sCurrentPtr->fmtString, "v");
strcpy(print_sCurrentPtr->fmtString, "v");
}
}
@@ -769,7 +769,7 @@ void func_802F79D0(s32 x, s32 y, u8* string, s32 arg3, s32 arg4){
if(print_sCurrentPtr){
print_sCurrentPtr->unk4 = arg3;
print_sCurrentPtr->unk6 = arg4;
strcpy(print_sCurrentPtr->fmtString, D_80377254); // strcpy(print_sCurrentPtr->fmtString, "delq");
strcpy(print_sCurrentPtr->fmtString, "delq");
}
}

View File

@@ -222,11 +222,11 @@ void func_802FD80C(s32 arg0, struct8s * arg1){
if(arg0 == 0){
if(arg1->unk60 < 1.0f || arg1->unk60 >= 12.0f)
phi_f16 = D_803773A0;
phi_f16 = 0.333f;
}
if(arg0 == 1){
if(arg1->unk60 > 10.0f)
phi_f16 = D_803773A4;
phi_f16 = 0.333f;
}
if(arg0 < 6){
if(item_getCount(arg0) < 30){

View File

@@ -23,9 +23,6 @@ BKModelBin *func_8030A428(s32 arg0);
/* .data */
s32 D_8036B800;
/* .rodata */
extern f32 D_80377730;
/* .bss */
struct_7AF80_0 *D_80382390; //prop models ???
struct_7AF80_1 *D_80382394; //prop_sprites ???
@@ -35,7 +32,7 @@ void func_8030A2D0(Gfx **gfx, Mtx **mtx, Vtx **vtx, f32 arg3[3], f32 arg4[3], f3
BKModelBin * sp2C;
sp2C = func_8030A428(arg6);
func_8033A244(D_80377730);
func_8033A244(3700.0f);
func_8033A28C(1);
set_model_render_mode(1);
func_8033A1FC();

View File

@@ -684,7 +684,7 @@ void func_803106BC(s32 text_id, s32 arg1, ActorMarker *marker, void(*callback)(A
void func_80310A5C(s32 next_state, s32 arg1, s32 arg2, s32 arg3, s32 arg4){
s32 i;
f32 tmpf;
for(i = 0, tmpf = D_80378534; i< 2; i++){
for(i = 0, tmpf = 0.4f; i< 2; i++){
if(D_80382E20.zoombox[i]){
func_803184C8(D_80382E20.zoombox[i], arg2, next_state, arg1, tmpf, arg3, arg4);
}

View File

@@ -63,12 +63,6 @@ extern s32 D_8036E5B0[4];
extern s32 D_8036E5C0[4];
/* .rodata */
extern f32 D_80378E50;
extern f64 D_80378E58;
extern f64 D_80378E60;
extern f64 D_80378E68;
/* .bss */
Actor *D_80383390;
s32 D_80383394;
@@ -661,7 +655,7 @@ Actor *func_80326D68(f32 position[3], enum actor_e actor_id, s32 arg2, f32 *min_
if (D_8036E560 != NULL) {
begin = D_8036E560->data;
closest_actor = NULL;
min_dist = D_80378E50;
min_dist = 1e+10f;
for(i_actor = begin; (i_actor - begin) < D_8036E560->cnt; i_actor++){
if ( ((actor_id == i_actor->modelCacheIndex) || (actor_id < 0))
&& (arg2 != i_actor->state)
@@ -1154,7 +1148,7 @@ void func_80328478(f32 arg0[3], f32 arg1, f32 arg2){
sp1C[0] = arg2;
sp1C[1] = 0.0f;
sp1C[2] = 0.0f;
ml_vec3f_yaw_rotate_copy(sp1C, sp1C, arg1 - D_80378E58);
ml_vec3f_yaw_rotate_copy(sp1C, sp1C, arg1 - 90.0);
arg0[0] += sp1C[0];
arg0[1] += sp1C[1];
@@ -1212,8 +1206,8 @@ int func_8032863C(AnimCtrl *anim_ctrl, f32 min, f32 max) {
return -1;
}
sp18 = animctrl_isPlayedForwards(anim_ctrl);
if( ((sp18 == 0) && (min <= timer) && (timer < (min + D_80378E60)))
|| ((sp18 == 1) && (timer < max) && ((max - D_80378E68) <= timer))
if( ((sp18 == 0) && (min <= timer) && (timer < (min + 0.015)))
|| ((sp18 == 1) && (timer < max) && ((max - 0.015) <= timer))
) {
sp18 = (sp18) ? 0 : 1;
animctrl_setDirection(anim_ctrl, sp18);

View File

@@ -370,12 +370,6 @@ extern GeoListFunc D_80370994[] = {
func_8033878C
};
/* .rodata */
extern f32 D_80378F40;
extern f32 D_80378F44;
extern f32 D_80378F48;
extern f32 D_80378F4C;
/* .bss */
s32 D_80383650;
s32 D_80383658[0x2A];
@@ -434,7 +428,7 @@ f32 D_80383C98[3];
/* .code */
void func_80338390(void){
D_80383700 = 0;
D_80383708 = D_80378F40;
D_80383708 = 30000.0f;
D_80383704 = TRUE;
D_8038370C = 1.0f;
D_80383710 = FALSE;
@@ -820,9 +814,9 @@ int func_803391A4(Gfx **gfx, Mtx **mtx, f32 position[3], f32 arg3[3], f32 scale,
spF4[1] = spE0[1] - D_80383C38[1];
spF4[2] = spE0[2] - D_80383C38[2];
if( ((spF4[0] < D_80378F44) || (D_80378F48 < spF4[0]))
|| ((spF4[1] < D_80378F44) || (D_80378F48 < spF4[1]))
|| ((spF4[2] < D_80378F44) || (D_80378F48 < spF4[2]))
if( ((spF4[0] < -17000.0f) || (17000.0f < spF4[0]))
|| ((spF4[1] < -17000.0f) || (17000.0f < spF4[1]))
|| ((spF4[2] < -17000.0f) || (17000.0f < spF4[2]))
){
func_80338390();
return 0;
@@ -977,7 +971,7 @@ int func_803391A4(Gfx **gfx, Mtx **mtx, f32 position[3], f32 arg3[3], f32 scale,
if(D_80383C54->geo_typ_A & 4){ //env mapping
if(0.0f == spF4[2]){
spF4[2] = D_80378F4C;
spF4[2] = -0.1f;
}
func_8024128C(*mtx, D_803837E0.unk400, D_803837E0.unk408[0], D_803837E0.unk408[1], D_803837E0.unk408[2], spF4[0], spF4[1], spF4[2], 0.0f, 1.0f, 0.0f);
gSPLookAt((*gfx)++, D_803837E0.unk400);

View File

@@ -13,7 +13,6 @@ extern u8 D_80370A14; //assetCache_size;
extern u8 D_80370A18;
extern s32 D_80370A10;
extern f32 D_80378F50;
/* .bss */
s32 D_80383CB0;
@@ -39,7 +38,7 @@ void func_8033BAB0(enum asset_e asset_id, s32 offset, s32 size, void *dst_ptr);
/* .core2 */
f32 func_8033AA10(AnimationFile *this, s32 arg1){
if(arg1 == this->unk2)
return D_80378F50;
return 0.999999f;
return (f32)(arg1 - this->unk0)/(f32)(this->unk2 - this->unk0);
}

View File

@@ -2,8 +2,6 @@
#include "functions.h"
#include "variables.h"
/* .rodata */
extern f64 D_80378F80;
/* .bss */
s32 D_80384470;
@@ -24,6 +22,6 @@ void func_8033DC18(void){}
f32 func_8033DC20(void){
f32 out;
D_80384470 = func_8024BD94();
out = D_80378F80*D_80384470;
out = 0.016666666666666666*D_80384470;
return out;
}

View File

@@ -227,12 +227,6 @@ extern s32 D_80371E80;
extern char D_80378FF0[];
extern f32 D_8037901C;
extern f64 D_80379058;
extern f64 D_80379060;
extern f64 D_80379068;
extern f64 D_80379070;
/* .bss */
s16 *D_803858A0;
@@ -973,8 +967,8 @@ void func_803430B4(Actor *arg0) {
if (d_yaw >= 180.0f) {
d_yaw = 360.0f - d_yaw;
}
arg0->unk10_3 = (d_yaw < D_80379058) ? 3
: (d_yaw < D_80379060) ? 2
arg0->unk10_3 = (d_yaw < 1.8) ? 3
: (d_yaw < 3.2) ? 2
: 1;
}
}
@@ -1006,7 +1000,7 @@ void func_803431D0(Actor *arg0, s32 arg1, s32 arg2, s32 arg3) {
}
}
if (arg1 & 0x200) {
arg0->unk6C = (D_80379068 - sp58[0]);
arg0->unk6C = (360.0 - sp58[0]);
}
}
}
@@ -1098,7 +1092,7 @@ s32 func_80343694(Actor *actor, s32 indx, s32 begin, s32 end, s32 count, s32 str
}
}
if ((D_80371E80 == 1) && (var_v1 == 1)) {
actor->unk48 = sp48 + D_80379070;
actor->unk48 = sp48 + 0.00001;
}
return var_v1;
}

View File

@@ -50,9 +50,6 @@ void func_80348044(Gfx **gfx, BKSprite* sprite, s32 frame, s32 tmem, s32 rtile,
((height)-1) << G_TEXTURE_IMAGE_FRAC) \
}
/* .rodata */
extern f64 D_80379140;
/* .bss */
s32 D_80386070;
s32 D_80386074;
@@ -94,7 +91,7 @@ void func_80347E60(Struct81s *arg0) {
actor = marker_getActor(arg0->marker);
if (actor->unk54 > 0.0) {
temp_f0 = sinf((actor->unk54 * D_80379140) / 3.0);
temp_f0 = sinf((actor->unk54 * M_PI) / 3.0);
if (temp_f0 < 0.0f) {
var_f12 = 0.0f;
} else {

View File

@@ -24,7 +24,7 @@ f32 func_8034A9D0(f32 arg0[4], f32 arg1) {
void func_8034AA70(f32 arg0[4]){
arg0[1] = D_80379170;
arg0[1] = 10000.0f;
arg0[0] = 4000.0f;
arg0[3] = 2000.0f;
arg0[2] = -500.0f;

View File

@@ -43,7 +43,7 @@ void func_8034F774(void){
particleEmitter_setStartingFrameRange(D_803720A0.unk0, 0, 4);
particleEmitter_setParticleFramerateRange(D_803720A0.unk0, 15.0f, 30.0f);
particleEmitter_setSpawnIntervalRange(D_803720A0.unk0, 0.0f, 1.0f);
func_802EFEC0(D_803720A0.unk0, D_803792F0, D_803792F0);
func_802EFEC0(D_803720A0.unk0, 216000.0f, 216000.0f);
func_802EFB70(D_803720A0.unk0, 1.8f, 2.2f);
func_802EF4AC(D_803720A0.unk0, &sp38, &sp2C, 0xA);
particleEmitter_setSpawnInterval(D_803720A0.unk0, 0.0f);

View File

@@ -87,10 +87,10 @@ void func_8034F950(Struct_core2_C89C0_0 *arg0) {
ml_vec3f_yaw_rotate_copy(sp70, sp70, arg0->unk14);
ml_vec3f_normalize(sp7C);
if ((sp70[0]*sp7C[0] + sp70[1]*sp7C[1] + sp70[2]*sp7C[2]) < 0.0f) {
arg0->unk34 = randf2(D_80379300, D_80379304);
arg0->unk34 = randf2(0.1f, 0.3f);
arg0->unk30 = randf2(0.5f, 1.0f);
} else {
arg0->unk30 = (randf2(D_80379308, 1.0f) * func_80256AB4(sp70[0], sp70[2], sp7C[0], sp7C[2]));
arg0->unk30 = (randf2(0.1f, 1.0f) * func_80256AB4(sp70[0], sp70[2], sp7C[0], sp7C[2]));
}
arg0->unk30 = (arg0->unk30 > 1.0f) ? 1.0f : arg0->unk30;
arg0->unk30 = (arg0->unk30 < -1.0f) ? -1.0f : arg0->unk30;
@@ -121,7 +121,7 @@ Actor* func_8034FCDC(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx) {
sp2C[1] = sp28->unk14;
sp2C[2] = 0.0f;
set_model_render_mode(2);
func_803391A4(gfx, mtx, sp28->unk8, sp2C, sp28->unk18 * D_80379310, NULL, D_80386150.unk0);
func_803391A4(gfx, mtx, sp28->unk8, sp2C, sp28->unk18 * 0.1, NULL, D_80386150.unk0);
return NULL;
}
@@ -144,7 +144,7 @@ void func_8034FDA0(s32 arg0) {
D_80386150.unkC->unk1C = arg0;
D_80386150.unkC->unk20 = 10.0f;
D_80386150.unkC->unk24 = 20.0f;
D_80386150.unkC->unk28 = D_80379318;
D_80386150.unkC->unk28 = 0.01f;
D_80386150.unkC->unk2C = 0.0f;
func_80323240(func_80342038(D_80386150.unkC->unk1C), D_80386150.unkC->unk2C, D_80386150.unkC->unkC);
D_80386150.unkC++;

View File

@@ -448,9 +448,9 @@ void func_80351E60(Struct6Bs *arg0, Struct68s *arg1, f32 arg2) {
f32 sp24[3];
arg0->unk34 += arg2;
arg0->unk10[1] = sinf(((arg0->unk34 * arg0->unk0) / D_80379350) * D_80379358) * 20.0f;
arg0->unk4[0] = cosf(((arg0->unk34 * arg0->unk0) / D_80379360) * D_80379368) * 7.5;
arg0->unk4[1] = sinf(((arg0->unk34 * arg0->unk0) / D_80379370) * D_80379378) * 3.0f;
arg0->unk10[1] = sinf(((arg0->unk34 * arg0->unk0) / 180.0) * BAD_PI) * 20.0f;
arg0->unk4[0] = cosf(((arg0->unk34 * arg0->unk0) / 180.0) * BAD_PI) * 7.5;
arg0->unk4[1] = sinf(((arg0->unk34 * arg0->unk0) / 180.0) * BAD_PI) * 3.0f;
sp24[0] = arg0->unk1C[0] + arg0->unk10[0];
sp24[1] = arg0->unk1C[1] + arg0->unk10[1];
sp24[2] = arg0->unk1C[2] + arg0->unk10[2];

View File

@@ -6,11 +6,6 @@
extern u8 func_8033E8D0(void);
/* .rodata */
extern f32 D_803793F0;
extern f64 D_803793F8;
extern f32 D_80379400;
/* .code */
void func_803525A0(f32 arg0[3]){
u8 sp1F;
@@ -22,7 +17,7 @@ void func_803525A0(f32 arg0[3]){
sp18 = func_8033E960();
projectile_setPosition(sp1E, arg0);
func_80344D94(sp1F, arg0);
sp18[1] = D_803793F0;
sp18[1] = 0.45f;
}
}
@@ -70,10 +65,10 @@ void func_803526DC(void) {
func_8033FE2C(sp43, 9.0f);
temp_f16 = (s32) ml_map_f(temp_f20, 0.0f, sp38, sp30, 10.0f);
func_8033FFE4(sp43, temp_f16, temp_f16);
if (temp_f20 < D_803793F8) {
if (temp_f20 < 0.1) {
func_8033FC34(sp43, (s32) ml_map_f(temp_f20, 0.0f, 0.08f, 20.0f, 255.0f));
} else {
func_8033FC34(sp43, (s32) ml_map_f(temp_f20, D_80379400, sp38, 255.0f, 20.0f));
func_8033FC34(sp43, (s32) ml_map_f(temp_f20, 0.1f, sp38, 255.0f, 20.0f));
}
temp_f20 += time_getDelta();
temp_s0->unk0 = temp_f20;

View File

@@ -36,6 +36,7 @@ extern f32 D_80379438;
extern f64 D_80379440;
extern f64 D_80379448;
/* .code */
void fxegg_shatter(u8 projectile_indx){
f32 position[3];
@@ -143,7 +144,7 @@ bool fxegg_isCollidingWithPlayer(f32 arg0[3]){
player_getPosition(sp2C);
ml_vec3f_diff_copy(sp20, sp2C, arg0);
return (sp2C[1] < arg0[1]) && (arg0[1] < sp2C[1] + 100.0f)
&& (sp20[0]*sp20[0] + sp20[2]*sp20[2] < D_80379430);
&& (sp20[0]*sp20[0] + sp20[2]*sp20[2] < 4900.0f);
}
void func_80353580(ActorMarker *marker){
@@ -214,7 +215,7 @@ void fxegg_head_update(void){
sp78 = func_8033EA14(1);
tmp_f24 = func_8033EA14(2);
tmp_f24 -= time_getDelta();
sp6C = ml_map_f(sp78, 0.0f, 2.0f, 0.0333f, D_80379434);
sp6C = ml_map_f(sp78, 0.0f, 2.0f, 0.0333f, 0.1f);
while(tmp_f24 <= 0.0f){//L80353868
tmp_f24 += sp6C;
projectile_getPosition(projectile_indx, sp7C);
@@ -319,7 +320,7 @@ void fxegg_ass_update(void) {
sp64 = func_8033EA14(1);
var_f22 = func_8033EA14(2);
var_f22 -= time_getDelta();
sp58 = ml_map_f(sp64, 0.0f, 3.0f, 0.0333f, D_80379438);
sp58 = ml_map_f(sp64, 0.0f, 3.0f, 0.0333f, 0.1f);
while (var_f22 <= 0.0f) {
var_f22 += sp58;
projectile_getPosition(projectile_indx, sp68);
@@ -342,7 +343,7 @@ void fxegg_ass_update(void) {
}
func_803531C8(projectile_indx, 1);
func_80344E7C(sp8E, sp74);
if (D_80379440 < func_8033EA14(1)) {
if (0.6 < func_8033EA14(1)) {
projectile_getPosition(projectile_indx, sp80);
if (fxegg_isCollidingWithPlayer(sp80)) {
collect_egg(NULL);
@@ -355,7 +356,7 @@ void fxegg_ass_update(void) {
func_8033EA40(0, min_f(temp_f20 + 8.0f, 50.0f));
sp64 += time_getDelta();
func_8033EA40(1, sp64);
if ((D_80379448 < sp64) && (func_80344EC0(sp8E) || (sp64 > 3.5))) {
if ((2.8 < sp64) && (func_80344EC0(sp8E) || (sp64 > 3.5))) {
func_8033E984();
fxegg_shatter(projectile_indx);
}

View File

@@ -69,10 +69,10 @@ void func_8035451C(void) {
func_8033FE2C(temp_v0, 9.0f);
temp_f16 = ml_map_f(temp_f20, 0.0f, sp38, sp30, 20.0f);
func_8033FFE4(temp_v0, temp_f16, temp_f16);
if (temp_f20 < D_80379470) {
if (temp_f20 < 0.1) {
func_8033FC34(temp_v0, ml_map_f(temp_f20, 0.0f, 0.1f, 20.0f, 210.0f));
} else {
func_8033FC34(temp_v0, ml_map_f(temp_f20, D_80379478, sp38, 210.0f, 20.0f));
func_8033FC34(temp_v0, ml_map_f(temp_f20, 0.1f, sp38, 210.0f, 20.0f));
}
temp_f20 += time_getDelta();
temp_s0->unk0 = temp_f20;

View File

@@ -56,7 +56,7 @@ void func_803546E8(void) {
func_80344EE4(sp47, -700.0f, -22000.0f);
func_802589E4(sp28, D_803726EC, 250.0f);
sp28[1] = 250.0f;
D_803726EC = mlNormalizeAngle(D_803726EC + D_80379480);
D_803726EC = mlNormalizeAngle(D_803726EC + 45.0);
func_80344E3C(sp47, sp28);
func_80344D94(sp47, sp34);
temp_s0->unk20 = 0x14;
@@ -475,7 +475,7 @@ void func_80355864(void) {
func_802589E4(sp2C, D_803726EC, sp28);
sp2C[1] = sp28 * ((sp44 * 0.5) + 1.0);
D_803726EC = mlNormalizeAngle(D_803726EC + D_803794B0);
D_803726EC = mlNormalizeAngle(D_803726EC + 45.0);
func_80344E3C(sp57, sp2C);
func_80344D94(sp57, sp38);
sp48->unk20 = 0x14;

View File

@@ -88,11 +88,11 @@ void func_8035D2FC(Actor *this) {
local->unk10 = 0x10C; //SFX_10C_MUMMY_TALKING
local->unk12 = 20000;
local->unk14 = 1.5f;
local->unk18 = D_80379860;
local->unk18 = 0.2f;
local->unk1C = 0x10D; //SFX_10D_ANCIENT_ONE_TALKING
local->unk1E = 20000;
local->unk20 = D_80379864;
local->unk24 = D_80379868;
local->unk20 = 1.9f;
local->unk24 = 0.35f;
local->unk28 = 0xC5; //SFX_C5_TWINKLY_POP
local->unk2A = 20000;
local->unk2C = 1.0f;

View File

@@ -22,15 +22,6 @@ extern ActorInfo D_803730D8 = {
2500, 0, 0.9f, 0
};
/* .rodata */
extern f64 D_803799C0;
extern f64 D_803799C8;
extern f64 D_803799D0;
extern f64 D_803799D8;
extern f64 D_803799E0;
extern f64 D_803799E8;
/* .code */
void func_8035F970(Actor *this){
func_80328A84(this, 1);
@@ -195,10 +186,10 @@ bool func_8035FF5C(Actor *this){
}
void func_8035FFAC(Actor *this, f32 arg1){
if(arg1 < 0.0f && randf() < D_803799C0){
if(arg1 < 0.0f && randf() < 0.82){
this->velocity_y = 0.0f;
}
else if(randf() < D_803799C8){
else if(randf() < 0.92){
this->velocity_y = 1.0f;
}
}
@@ -239,7 +230,7 @@ bool func_80360198(Actor *this) {
func_80328FB0(this, 5.0f);
func_80360044(this);
this->unk28 += (this->velocity[1] * D_803799D0) - (D_803799D8 * this->unk28);
this->unk28 += (this->velocity[1] * 0.45) - (0.001 * this->unk28);
if (this->unk28 > 13.0) {
this->unk28 = 13.0f;
}
@@ -247,7 +238,7 @@ bool func_80360198(Actor *this) {
this->unk28 = -13.0f;
}
this->velocity[0] += ((this->velocity[1] * D_803799E0) - D_803799E8);
this->velocity[0] += ((this->velocity[1] * 0.9) - 0.6);
if (this->velocity[0] > 6.0) {
this->velocity[0] = 6.0f;
}