sm64pc/src/game/behaviors/end_birds_1.inc.c

30 lines
1.0 KiB
C
Raw Permalink Normal View History

2019-09-01 19:50:50 +00:00
// end_birds_1.inc.c
void bhv_end_birds_1_loop(void) {
Vec3f sp34;
2020-04-03 18:57:26 +00:00
UNUSED f32 sp30 = random_float();
2019-09-01 19:50:50 +00:00
switch (gCurrentObject->oAction) {
case 0:
2020-03-02 03:42:52 +00:00
cur_obj_scale(0.7f);
2019-09-01 19:50:50 +00:00
gCurrentObject->oIntroLakituUnk110 = -554.f;
gCurrentObject->oIntroLakituUnk10C = 3044.f;
gCurrentObject->oIntroLakituUnk108 = -1314.f;
gCurrentObject->oAction += 1;
break;
case 1:
vec3f_set(sp34, gCurrentObject->oIntroLakituUnk110, gCurrentObject->oIntroLakituUnk10C,
gCurrentObject->oIntroLakituUnk108);
if (gCurrentObject->oTimer < 100)
2020-01-03 15:38:57 +00:00
obj_rotate_towards_point(gCurrentObject, sp34, 0, 0, 0x20, 0x20);
2019-09-01 19:50:50 +00:00
if ((gCurrentObject->oEndBirdUnk104 == 0.f) && (gCurrentObject->oTimer == 0))
2020-03-02 03:42:52 +00:00
cur_obj_play_sound_2(SOUND_GENERAL_BIRDS_FLY_AWAY);
2019-09-01 19:50:50 +00:00
if (gCutsceneTimer == 0)
2020-03-02 03:42:52 +00:00
obj_mark_for_deletion(gCurrentObject);
2019-09-01 19:50:50 +00:00
break;
}
2020-03-02 03:42:52 +00:00
cur_obj_set_pos_via_transform();
2019-09-01 19:50:50 +00:00
}