mirror of
https://github.com/ACreTeam/ac-decomp
synced 2026-07-08 20:24:49 -04:00
Implement & link ef_pun.c (#411)
Includes fixes to ef_halloween_smoke.c and rel_slices.yml
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
#include "ef_effect_control.h"
|
||||
|
||||
#include "m_common_data.h"
|
||||
|
||||
static void eHalloween_Smoke_init(xyz_t pos, int prio, s16 angle, GAME* game, u16 item_name, s16 arg0, s16 arg1);
|
||||
static void eHalloween_Smoke_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg);
|
||||
static void eHalloween_Smoke_mv(eEC_Effect_c* effect, GAME* game);
|
||||
|
||||
+24
-4
@@ -1,5 +1,7 @@
|
||||
#include "ef_effect_control.h"
|
||||
|
||||
#include "m_common_data.h"
|
||||
|
||||
static void ePun_init(xyz_t pos, int prio, s16 angle, GAME* game, u16 item_name, s16 arg0, s16 arg1);
|
||||
static void ePun_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg);
|
||||
static void ePun_mv(eEC_Effect_c* effect, GAME* game);
|
||||
@@ -18,17 +20,35 @@ eEC_PROFILE_c iam_ef_pun = {
|
||||
};
|
||||
|
||||
static void ePun_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_PUN, pos, NULL, game, &angle, item_name, prio, 0, 0);
|
||||
}
|
||||
|
||||
static void ePun_ct(eEC_Effect_c* effect, GAME* game, void* ct_arg) {
|
||||
// TODO
|
||||
s16 var = *(s16*)ct_arg;
|
||||
effect->effect_specific[0] = var;
|
||||
effect->timer = 24;
|
||||
}
|
||||
|
||||
static void ePun_mv(eEC_Effect_c* effect, GAME* game) {
|
||||
// TODO
|
||||
eEC_CLIP->set_continious_env_proc(effect, 24, 44);
|
||||
|
||||
if (effect->state == eEC_STATE_CONTINUOUS) {
|
||||
s16 timer_left = 44 - effect->timer;
|
||||
|
||||
if (timer_left == 0) {
|
||||
effect->effect_specific[1] = RANDOM(100) & 1;
|
||||
}
|
||||
|
||||
if (timer_left == 8) {
|
||||
eEC_CLIP->effect_make_proc(eEC_EFFECT_PUN_YUGE, effect->position, effect->prio, effect->effect_specific[0], game, (u16)effect->item_name, effect->effect_specific[1], 0);
|
||||
|
||||
effect->effect_specific[1] = ++effect->effect_specific[1] & 1;
|
||||
|
||||
eEC_CLIP->effect_make_proc(eEC_EFFECT_PUN_SEKIMEN, effect->position, effect->prio, effect->effect_specific[0], game, (u16)effect->item_name, 0, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void ePun_dw(eEC_Effect_c* effect, GAME* game) {
|
||||
// TODO
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user