#include "libforest/gbi_extensions.h"
#include "PR/gbi.h"
#include "evw_anime.h"
#include "c_keyframe.h"
#include "ac_npc.h"
#include "ef_effect_control.h"

u8 cKF_ckcb_r_npc_1_landing3_tbl[] = { 56, 7, 0, 7, 7, 7, 0, 7, 7, 7, 0, 7, 7, 7, 0, 7, 7, 0, 7, 7, 7, 7, 0, 7, 0, 0 };

s16 cKF_kn_npc_1_landing3_tbl[] = { 2, 4, 5, 3, 4, 3, 5, 4, 4, 3, 5, 3, 3, 6, 3, 5, 4, 4, 3, 5, 3, 3, 6, 3, 2, 2, 2,
                                    2, 2, 2, 3, 4, 2, 2, 3, 5, 2, 2, 5, 2, 3, 5, 2, 2, 5, 2, 2, 2, 2, 4, 2, 2, 2, 2 };

s16 cKF_c_npc_1_landing3_tbl[] = { 3600, 0, 900, 0,   0, 1800, 0, 0, 1800, 0, 900, 0, 0,   0,
                                   -900, 0, 0,   900, 0, -900, 0, 0, 0,    0, 0,   0, -900 };

s16 cKF_ds_npc_1_landing3_tbl[] = {
    5,  0,    0,    16, 0,    0,     7,  1000, 0,     8,  1000, -17462, 9,  700,  0,     16, 1000, 0,
    5,  0,    0,    9,  -150, 0,     11, -100, 1701,  13, 0,    0,      16, 0,    0,     1,  0,    319,
    5,  0,    0,    16, 0,    0,     1,  440,  0,     5,  -50,  0,      9,  0,    0,     16, 0,    0,
    1,  0,    0,    5,  0,    0,     16, 0,    0,     1,  -100, 0,      6,  -150, 0,     9,  -150, 0,
    13, -130, 0,    16, -175, 0,     1,  -300, 0,     6,  -150, -2172,  9,  -530, 0,     16, -100, 0,
    1,  180,  0,    6,  50,   0,     9,  140,  0,     16, 25,   0,      1,  0,    0,     6,  0,    0,
    16, 0,    0,    1,  150,  0,     6,  200,  613,   9,  950,  0,      13, 700,  -4145, 16, 200,  0,
    1,  0,    0,    6,  0,    0,     16, 0,    0,     1,  0,    0,      6,  0,    0,     16, 0,    0,
    1,  50,   0,    6,  400,  0,     9,  -400, -772,  11, -420, 0,      13, -390, 824,   16, -100, 0,
    1,  0,    0,    6,  0,    0,     16, 0,    0,     1,  100,  0,      6,  150,  0,     9,  150,  0,
    13, 130,  0,    16, 175,  0,     1,  -300, 0,     6,  -150, -2168,  9,  -530, 0,     16, -100, 0,
    1,  -170, 0,    6,  -50,  0,     9,  -140, 0,     16, -25,  0,      1,  0,    0,     6,  0,    0,
    16, 0,    0,    1,  150,  0,     6,  200,  637,   9,  950,  0,      13, 700,  -4099, 16, 200,  0,
    1,  0,    0,    6,  0,    0,     16, 0,    0,     1,  0,    0,      6,  0,    0,     16, 0,    0,
    1,  50,   0,    6,  400,  0,     9,  -400, -838,  11, -420, 0,      13, -390, 660,   16, -100, 0,
    1,  0,    0,    6,  0,    0,     16, 0,    0,     1,  0,    0,      16, 0,    0,     1,  60,   0,
    16, 60,   0,    1,  0,    0,     16, 0,    0,     1,  0,    0,      16, 0,    0,     1,  80,   0,
    16, 80,   0,    1,  0,    0,     16, 0,    0,     1,  0,    -310,   5,  0,    0,     16, 0,    0,
    1,  -530, 0,    5,  100,  0,     10, -100, 0,     16, 2,    76,     1,  0,    0,     16, 0,    0,
    1,  -100, 0,    16, 0,    0,     1,  -100, 0,     5,  0,    395,    16, 58,   0,     1,  -600, 0,
    3,  -300, 6843, 5,  300,  0,     13, -600, 0,     16, -564, 0,      1,  0,    0,     16, 0,    0,
    1,  -57,  0,    16, -57,  0,     1,  0,    -7030, 6,  600,  0,      10, 500,  -1988, 13, -100, 0,
    16, 0,    0,    1,  100,  0,     16, 0,    0,     1,  -100, 0,      5,  0,    409,   16, 58,   0,
    1,  600,  0,    3,  300,  -7363, 5,  -300, 0,     13, 600,  0,      16, 564,  0,     1,  0,    0,
    16, 0,    0,    1,  -57,  0,     16, -57,  0,     1,  0,    6004,   6,  -600, 0,     10, -500, 1955,
    13, 100,  0,    16, 0,    0,     1,  0,    0,     16, 0,    0,      1,  0,    0,     16, 0,    0,
    1,  0,    0,    16, 0,    0,     1,  0,    0,     16, 0,    0,      1,  -200, 0,     5,  100,  0,
    11, -150, 0,    16, 0,    0,     1,  0,    0,     16, 0,    0,      1,  0,    0,     16, 0,    0,
    1,  0,    0,    16, 0,    0,     1,  0,    0,     16, 0,    0
};

static int other_se_chk_pat[] = { 9 };

static aNPC_other_se_data_c other_se_dt[] = { { { ARRAY_COUNT(other_se_chk_pat), other_se_chk_pat }, 1067 } };

static aNPC_se_data_table_c se_dt_tbl[] = { { NULL, NULL, aNPC_OTHER_SE_TYPE1, other_se_dt } };

aNPC_Animation_c cKF_ba_r_npc_1_landing3 = {
    { cKF_ckcb_r_npc_1_landing3_tbl, cKF_ds_npc_1_landing3_tbl, cKF_kn_npc_1_landing3_tbl, cKF_c_npc_1_landing3_tbl, -1,
      16 },
    1.0f,
    16.0f,
    cKF_FRAMECONTROL_STOP,
    -5.0f,
    NULL,
    aNPC_EYE_TEX0,
    0,
    NULL,
    aNPC_MOUTH_TEX0,
    0,
    -1,
    -1,
    NULL,
    se_dt_tbl,
};
