kankyo_rain / obj_life_container mostly done, obj_glowsphere done (#2266)

* obj_life_container mostly done

* obj_glowSphere done

* kankyo_rain mostly done

* some cleanup

* more kankyo_rain cleanup
This commit is contained in:
TakaRikka
2024-12-18 10:02:52 -08:00
committed by GitHub
parent c5ab943cfc
commit ff5f31b844
26 changed files with 6797 additions and 3980 deletions
+2 -2
View File
@@ -262,8 +262,8 @@ static void odour_move(kytag03_class* i_this) {
}
effect->mBasePos.z += temp_f22 * cM_rndFX(50.0f);
effect->field_0x1c = spFC.x;
effect->field_0x1e = spFC.y;
effect->mRotX = spFC.x;
effect->mRotY = spFC.y;
effect->field_0x2c = cM_rndF(20.0f) + 45.0f +
temp_f22 * (cM_rndF(20.0f) + 100.0f);
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+24
View File
@@ -1037,6 +1037,14 @@ static int phase_3(char*) {
/* 8002CEBC-8002CEFC 0277FC 0040+00 0/0 7/7 550/550 .text
* dComIfG_resLoad__FP30request_of_phase_process_classPCc */
/**
* Attempts to load a Resource Archive (*.arc) into the Resource Control.
* The archive must be successfully loaded into the Resource Control before
* calling dComIfG_getObjectRes / dComIfG_getStageRes
* @param i_phase Pointer to phase request for handling resource loading process
* @param i_arcName Name of archive to be loaded
* @return Loading phase state. cPhs_COMPLEATE_e if loaded successfully
*/
int dComIfG_resLoad(request_of_phase_process_class* i_phase, char const* i_arcName) {
static int (*l_method[3])(void*) = {(int (*)(void*))phase_1, (int (*)(void*))phase_2,
(int (*)(void*))phase_3};
@@ -1078,6 +1086,15 @@ static int phase_03(phaseParam_c*) {
/* 8002CFC0-8002D008 027900 0048+00 1/1 3/3 0/0 .text
* dComIfG_resLoad__FP30request_of_phase_process_classPCcP7JKRHeap */
/**
* Attempts to load a Resource Archive (*.arc) into the Resource Control using a specified heap.
* The archive must be successfully loaded into the Resource Control before
* calling dComIfG_getObjectRes / dComIfG_getStageRes
* @param i_phase Pointer to phase request for handling resource loading process
* @param i_arcName Name of archive to be loaded
* @param i_heap Pointer to heap to load resources into
* @return Loading phase state. cPhs_COMPLEATE_e if loaded successfully
*/
int dComIfG_resLoad(request_of_phase_process_class* i_phase, char const* i_resName,
JKRHeap* i_heap) {
static int (*l_method[3])(void*) = {(int (*)(void*))phase_01, (int (*)(void*))phase_02,
@@ -1093,6 +1110,13 @@ int dComIfG_resLoad(request_of_phase_process_class* i_phase, char const* i_resNa
/* 8002D008-8002D06C 027948 0064+00 1/1 10/10 540/540 .text
* dComIfG_resDelete__FP30request_of_phase_process_classPCc */
/**
* Attempts to unload a Resource Archive (*.arc) from the Resource Control.
* This should be called from a process' delete method to prevent a memory leak.
* @param i_phase Pointer to phase request for handling resource unloading process
* @param i_arcName Name of archive to be unloaded
* @return TRUE if successful, FALSE otherwise
*/
int dComIfG_resDelete(request_of_phase_process_class* i_phase, char const* i_resName) {
if (i_phase->id != cPhs_NEXT_e) {
return 0;
+2 -2
View File
@@ -1216,8 +1216,8 @@ static void setkankyoShadow(dKy_tevstr_c* param_0, f32* param_1) {
*param_1 *= param_0->field_0x344;
}
if (env_light->mThunderEff.mStateTimer != 0 && env_light->mThunderEff.mStateTimer < 10) {
*param_1 += env_light->mThunderEff.field_0x8;
if (env_light->mThunderEff.mState != 0 && env_light->mThunderEff.mState < 10) {
*param_1 += env_light->mThunderEff.mFlashTimer;
}
if (g_env_light.mSwordLight.mState == 2) {
+3 -3
View File
@@ -1145,7 +1145,7 @@ static void envcolor_init() {
g_env_light.field_0x1230 = 0.0f;
g_env_light.field_0x1234 = 0.0f;
g_env_light.mThunderEff.mStateTimer = 0;
g_env_light.mThunderEff.mState = 0;
g_env_light.field_0x1238 = 0.0f;
g_env_light.field_0x123c = 0.0f;
g_env_light.field_0x12d6 = 0;
@@ -3492,7 +3492,7 @@ SECTION_DEAD static char const* const stringBase_80394E70 = "D_MN";
#pragma pop
/* 801A6D4C-801A6E9C 1A168C 0150+00 1/1 1/1 0/0 .text dKy_move_room_ratio__FP12dKy_tevstr_cPSc */
void dKy_move_room_ratio(dKy_tevstr_c* param_0, s8* param_1) {
f32 dKy_move_room_ratio(dKy_tevstr_c* param_0, s8* param_1) {
// NONMATCHING
}
@@ -3816,7 +3816,7 @@ void dKy_SordFlush_set(cXyz param_0, int param_1) {
dScnKy_env_light_c* light = dKy_getEnvlight();
if (!dKy_darkworld_check() &&
(light->mThunderEff.mStateTimer >= 10 || light->mThunderEff.field_0x8 <= 0.0f))
(light->mThunderEff.mState >= 10 || light->mThunderEff.mFlashTimer <= 0.0f))
{
if (g_env_light.mSwordLight.mState == 0) {
g_env_light.mSwordLight.mState = 1;
+5100 -1879
View File
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -101,7 +101,7 @@ STAR_EFF::STAR_EFF() {}
/* 80056E08-80056E38 051748 0030+00 1/0 0/0 0/0 .text draw__19dKankyo_star_PacketFv */
void dKankyo_star_Packet::draw() {
dKyr_drawStar(j3dSys.getViewMtx(), &field_0x10);
dKyr_drawStar(j3dSys.getViewMtx(), &mpTex);
}
/* 80056E38-80056E74 051778 003C+00 2/2 0/0 0/0 .text __dt__9CLOUD_EFFFv */
@@ -540,7 +540,7 @@ static void wether_move_sun() {
g_env_light.mpSunPacket->mVisibility = 0.0f;
g_env_light.mpSunPacket->mSunAlpha = 0.0f;
g_env_light.mpSunPacket->field_0x64 = 0.0f;
g_env_light.mpSunPacket->field_0x68 = 0.0f;
g_env_light.mpSunPacket->mMoonAlpha = 0.0f;
if (g_env_light.mDaytime < 255.0f) {
g_env_light.mpSunPacket->field_0x6c = 1.0f;
+4 -4
View File
@@ -69,7 +69,7 @@ static int dThunder_Draw(dThunder_c* i_this) {
int dThunder_c::execute(dThunder_c* i_thunder) {
dScnKy_env_light_c* env_light = dKy_getEnvlight();
if (env_light->mThunderEff.mStateTimer < 10) {
if (env_light->mThunderEff.mState < 10) {
cLib_addCalc(&mBrkSpeed, 0.1f, 0.05f, 0.017f, 9.999999747378752e-06f);
}
@@ -93,7 +93,7 @@ int dThunder_c::execute(dThunder_c* i_thunder) {
fvar7 *= mBrkSpeed;
if (env_light->mThunderEff.mStateTimer < 10) {
if (env_light->mThunderEff.mState < 10) {
field_0x138.x += fvar7 * field_0x138.x * 0.01f * cM_ssin(field_0x16a);
field_0x138.y += fvar7 * field_0x138.y * 0.01f * cM_scos(field_0x16c);
field_0x16a += -25000;
@@ -180,7 +180,7 @@ int dThunder_c::create() {
mBrkSpeed = 1.0f;
mModelInfo.mBrk.setPlaySpeed(mBrkSpeed);
if (env_light->mThunderEff.mStateTimer < 10) {
if (env_light->mThunderEff.mState < 10) {
var_f29 = 1.0f;
} else {
var_f29 = 0.25f;
@@ -199,7 +199,7 @@ int dThunder_c::create() {
spC4.set(60000.0f, -5000.0f, 0.0f);
field_0x15c = 2000.0f;
if (env_light->mThunderEff.mStateTimer >= 10) {
if (env_light->mThunderEff.mState >= 10) {
var_f31 = var_r27;
var_f30 = 24.0f;
field_0x15c = 2500.0f;
+354 -249
View File
File diff suppressed because it is too large Load Diff