mirror of
https://github.com/ACreTeam/ac-decomp
synced 2026-05-23 06:34:18 -04:00
Merge pull request #489 from Norgesnerd/master
Implement & link ef_kisha_kemuri, ef_muka, ef_neboke
This commit is contained in:
+3
-3
@@ -1284,7 +1284,7 @@ config.libs = [
|
||||
Object(Matching, "effect/ef_kigae_light.c"),
|
||||
Object(Matching, "effect/ef_kikuzu.c"),
|
||||
Object(Matching, "effect/ef_killer.c"),
|
||||
Object(NonMatching, "effect/ef_kisha_kemuri.c"),
|
||||
Object(Matching, "effect/ef_kisha_kemuri.c"),
|
||||
Object(NonMatching, "effect/ef_konpu.c"),
|
||||
Object(NonMatching, "effect/ef_kpun.c"),
|
||||
Object(Matching, "effect/ef_kyousou_onpu.c"),
|
||||
@@ -1295,10 +1295,10 @@ config.libs = [
|
||||
Object(Matching, "effect/ef_make_hem.c"),
|
||||
Object(NonMatching, "effect/ef_mizutama.c"),
|
||||
Object(NonMatching, "effect/ef_motiyuge.c"),
|
||||
Object(NonMatching, "effect/ef_muka.c"),
|
||||
Object(Matching, "effect/ef_muka.c"),
|
||||
Object(Matching, "effect/ef_naku.c"),
|
||||
Object(NonMatching, "effect/ef_namida.c"),
|
||||
Object(NonMatching, "effect/ef_neboke.c"),
|
||||
Object(Matching, "effect/ef_neboke.c"),
|
||||
Object(NonMatching, "effect/ef_neboke_akubi.c"),
|
||||
Object(NonMatching, "effect/ef_neboke_awa.c"),
|
||||
Object(Matching, "effect/ef_night13_moon.c"),
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
#include "ef_effect_control.h"
|
||||
|
||||
#include "m_common_data.h"
|
||||
|
||||
extern Gfx ef_kisha_kemuri01_modelT[];
|
||||
|
||||
static void eKishaK_init(xyz_t pos, int prio, s16 angle, GAME* game, u16 item_name, s16 arg0, s16 arg1);
|
||||
static void eKishaK_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg);
|
||||
static void eKishaK_mv(eEC_Effect_c* effect, GAME* game);
|
||||
@@ -18,17 +22,53 @@ eEC_PROFILE_c iam_ef_kisha_kemuri = {
|
||||
};
|
||||
|
||||
static void eKishaK_init(xyz_t pos, int prio, s16 angle, GAME* game, u16 item_name, s16 arg0, s16 arg1) {
|
||||
// TODO
|
||||
eEC_CLIP->make_effect_proc(eEC_EFFECT_KISHA_KEMURI, pos, NULL, game, NULL, item_name, prio, arg0, angle);
|
||||
}
|
||||
|
||||
static void eKishaK_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg) {
|
||||
// TODO
|
||||
f32 x, y;
|
||||
|
||||
effect->scale.x = 0.0f;
|
||||
effect->scale.y = 0.0f;
|
||||
effect->scale.z = 0.0f;
|
||||
|
||||
effect->timer = 80;
|
||||
|
||||
x = RANDOM_F(5.0f) - 2.5f;
|
||||
y = RANDOM_F(5.0f) - 2.5f;
|
||||
effect->position.x += x;
|
||||
effect->position.z += y;
|
||||
|
||||
if (effect->arg0 == 1) {
|
||||
effect->acceleration.x = sin_s(effect->arg1) * 0.2f;
|
||||
effect->acceleration.z = cos_s(effect->arg1) * 0.2f;
|
||||
}
|
||||
}
|
||||
|
||||
static void eKishaK_mv(eEC_Effect_c* effect, GAME* game) {
|
||||
// TODO
|
||||
effect->position.y += eEC_CLIP->calc_adjust_proc(80 - effect->timer, 0, 20, 2.2f, 0.5f);
|
||||
if (effect->arg0 == 1) {
|
||||
effect->position.x += effect->acceleration.x;
|
||||
effect->position.z += effect->acceleration.z;
|
||||
}
|
||||
}
|
||||
|
||||
static void eKishaK_dw(eEC_Effect_c* effect, GAME* game) {
|
||||
// TODO
|
||||
s16 timer = 80 - effect->timer;
|
||||
xyz_t* scale = &effect->scale;
|
||||
u8 alpha = (int)eEC_CLIP->calc_adjust_proc(timer, 40, 80, 200.0f, 4.0f);
|
||||
f32 new_scale = eEC_CLIP->calc_adjust_proc(timer, 0, 40, 0.003f, 0.027f);
|
||||
|
||||
scale->x = new_scale;
|
||||
scale->y = new_scale;
|
||||
scale->z = new_scale;
|
||||
|
||||
OPEN_DISP(game->graph);
|
||||
|
||||
eEC_CLIP->auto_matrix_xlu_proc(game, &effect->position, scale);
|
||||
|
||||
gDPSetPrimColor(NEXT_POLY_XLU_DISP, 0, 128, 30, 30, 30, alpha);
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_kisha_kemuri01_modelT);
|
||||
|
||||
CLOSE_DISP(game->graph);
|
||||
}
|
||||
|
||||
+39
-4
@@ -1,5 +1,9 @@
|
||||
#include "ef_effect_control.h"
|
||||
|
||||
#include "m_common_data.h"
|
||||
|
||||
extern Gfx ef_muka01_00_modelT[];
|
||||
|
||||
static void eMK_init(xyz_t pos, int prio, s16 angle, GAME* game, u16 item_name, s16 arg0, s16 arg1);
|
||||
static void eMK_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg);
|
||||
static void eMK_mv(eEC_Effect_c* effect, GAME* game);
|
||||
@@ -18,17 +22,48 @@ eEC_PROFILE_c iam_ef_muka = {
|
||||
};
|
||||
|
||||
static void eMK_init(xyz_t pos, int prio, s16 angle, GAME* game, u16 item_name, s16 arg0, s16 arg1) {
|
||||
// TODO
|
||||
eEC_CLIP->make_effect_proc(eEC_EFFECT_MUKA, pos, NULL, game, &angle, item_name, prio, 0, 0);
|
||||
}
|
||||
|
||||
static void eMK_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg) {
|
||||
// TODO
|
||||
s16 angle, angle_y;
|
||||
|
||||
effect->scale.x = 0.0075f;
|
||||
effect->scale.y = 0.0075f;
|
||||
effect->scale.z = 0.0075f;
|
||||
|
||||
angle_y = (s16)getCamera2AngleY((GAME_PLAY*)game);
|
||||
angle = *(s16*)ct_arg;
|
||||
if (DIFF_USHORT_ANGLE(angle, (s16)(angle_y + DEG2SHORT_ANGLE(180.0f))) > DEG2SHORT_ANGLE2(180.0f)) {
|
||||
effect->offset.x = -10.0f;
|
||||
} else {
|
||||
effect->offset.x = 10.0f;
|
||||
}
|
||||
effect->offset.y = 9.0f;
|
||||
effect->offset.z = 23.0f;
|
||||
|
||||
effect->timer = 40;
|
||||
|
||||
sAdo_OngenTrgStart(0x137, &effect->position);
|
||||
}
|
||||
|
||||
static void eMK_mv(eEC_Effect_c* effect, GAME* game) {
|
||||
// TODO
|
||||
return;
|
||||
}
|
||||
|
||||
static void eMK_dw(eEC_Effect_c* effect, GAME* game) {
|
||||
// TODO
|
||||
s16 timer = 40 - effect->timer;
|
||||
u8 prim_g = (int)eEC_CLIP->calc_adjust_proc(timer, 0, 20, 255.0f, 50.0f);
|
||||
u8 prim_a = (int)eEC_CLIP->calc_adjust_proc(timer, 20, 41, 255.0f, 0.0f);
|
||||
u8 env_r = (int)eEC_CLIP->calc_adjust_proc(timer, 0, 20, 255.0f, 100.0f);
|
||||
|
||||
OPEN_DISP(game->graph);
|
||||
|
||||
eEC_CLIP->auto_matrix_xlu_offset_proc(game, &effect->position, &effect->scale, &effect->offset);
|
||||
|
||||
gDPSetPrimColor(NEXT_POLY_XLU_DISP, 0, 128, 255, prim_g, 50, prim_a);
|
||||
gDPSetEnvColor(NEXT_POLY_XLU_DISP, env_r, 30, 30, 255);
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_muka01_00_modelT);
|
||||
|
||||
CLOSE_DISP(game->graph);
|
||||
}
|
||||
|
||||
+28
-4
@@ -1,5 +1,7 @@
|
||||
#include "ef_effect_control.h"
|
||||
|
||||
#include "m_common_data.h"
|
||||
|
||||
static void eNebo_init(xyz_t pos, int prio, s16 angle, GAME* game, u16 item_name, s16 arg0, s16 arg1);
|
||||
static void eNebo_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg);
|
||||
static void eNebo_mv(eEC_Effect_c* effect, GAME* game);
|
||||
@@ -18,17 +20,39 @@ eEC_PROFILE_c iam_ef_neboke = {
|
||||
};
|
||||
|
||||
static void eNebo_init(xyz_t pos, int prio, s16 angle, GAME* game, u16 item_name, s16 arg0, s16 arg1) {
|
||||
// TODO
|
||||
eEC_CLIP->make_effect_proc(eEC_EFFECT_NEBOKE, pos, NULL, game, &angle, item_name, prio, 0, 0);
|
||||
}
|
||||
|
||||
static void eNebo_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg) {
|
||||
// TODO
|
||||
effect->timer = 112;
|
||||
effect->effect_specific[0] = *(s16*)ct_arg;
|
||||
}
|
||||
|
||||
static void eNebo_mv(eEC_Effect_c* effect, GAME* game) {
|
||||
// TODO
|
||||
s16 timer;
|
||||
|
||||
eEC_CLIP->set_continious_env_proc(effect, 112, 120);
|
||||
|
||||
if (effect->state == eEC_STATE_NORMAL) {
|
||||
timer = 112 - effect->timer;
|
||||
if (timer == 16) {
|
||||
eEC_CLIP->effect_make_proc(eEC_EFFECT_NEBOKE_AKUBI, effect->position, effect->prio,
|
||||
effect->effect_specific[0], game, (u16)effect->item_name, 0, 0);
|
||||
} else if (timer == 44) {
|
||||
eEC_CLIP->effect_make_proc(eEC_EFFECT_NEBOKE_AKUBI, effect->position, effect->prio,
|
||||
effect->effect_specific[0], game, (u16)effect->item_name, 1, 0);
|
||||
}
|
||||
} else if (effect->state == eEC_STATE_CONTINUOUS) {
|
||||
timer = 120 - effect->timer;
|
||||
switch (timer) {
|
||||
case 46:
|
||||
case 74:
|
||||
eEC_CLIP->effect_make_proc(eEC_EFFECT_NEBOKE_AWA, effect->position, effect->prio,
|
||||
effect->effect_specific[0], game, (u16)effect->item_name, 1, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void eNebo_dw(eEC_Effect_c* effect, GAME* game) {
|
||||
// TODO
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user