#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_kokeru1_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_kokeru1_tbl[] = { 2, 5, 3, 4, 4, 2, 4, 5, 4, 2, 5, 2, 4, 4, 2, 4, 5, 4, 2, 5, 2, 4, 4, 2, 2, 5, 5,
                                   2, 5, 4, 4, 4, 2, 4, 4, 4, 2, 4, 2, 3, 5, 4, 2, 4, 2, 6, 6, 5, 4, 4, 4, 2, 2, 2 };

s16 cKF_c_npc_1_kokeru1_tbl[] = { 0,    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_kokeru1_tbl[] = {
    1,  0,    0,    17, 0,    0,    1,  1027,  0,     5,  1200,  0,     8,  1000,  -4006, 11, 500,  0,
    17, 500,  0,    1,  0,    0,    11, -1000, 0,     17, -1000, 0,     1,  -55,   0,     5,  300,  0,
    11, -150, 0,    17, 0,    557,  1,  -50,   0,     5,  -200,  -2270, 11, -1000, 0,     17, -850, 609,
    1,  0,    0,    17, 0,    0,    1,  -20,   0,     5,  200,   0,     11, -200,  -1145, 17, -250, 524,
    1,  -143, 0,    5,  -350, 0,    8,  -150,  4482,  11, 350,   0,     17, -200,  0,     1,  20,   0,
    5,  -250, 0,    11, 20,   1934, 17, 200,   0,     1,  0,     0,     17, 0,     0,     1,  0,    0,
    5,  250,  0,    9,  200,  0,    13, 340,   1010,  17, 400,   0,     1,  0,     0,     17, 0,    0,
    1,  0,    0,    5,  100,  0,    14, 0,     0,     17, 0,     0,     1,  -65,   0,     5,  300,  1836,
    11, 400,  -315, 17, 250,  0,    1,  0,     0,     17, 0,     0,     1,  0,     0,     5,  400,  0,
    11, 0,    0,    17, 100,  0,    1,  -265,  0,     5,  -350,  0,     8,  -250,  2357,  11, 50,   0,
    17, -500, 0,    1,  0,    0,    5,  -150,  0,     11, 0,     0,     17, -100,  0,     1,  0,    0,
    17, 0,    0,    1,  1000, 0,    5,  800,   -3399, 9,  200,   0,     14, 900,   0,     17, 800,  0,
    1,  0,    0,    17, 0,    0,    1,  0,     0,     5,  -250,  0,     13, 0,     0,     17, 0,    0,
    1,  110,  0,    5,  -50,  0,    13, 150,   1308,  17, 270,   551,   1,  0,     0,     17, 2,    0,
    1,  0,    0,    17, 0,    0,    1,  -50,   0,     5,  375,   2194,  9,  450,   -490,  13, 50,   -1489,
    17, 0,    496,  1,  0,    0,    5,  -150,  0,     9,  150,   0,     13, 25,    -568,  17, 0,    0,
    1,  0,    0,    17, 0,    0,    1,  -50,   0,     5,  250,   1496,  9,  300,   -368,  15, -125, -1135,
    17, -150, 0,    1,  0,    0,    7,  -250,  438,   12, 200,   0,     17, 0,     0,     1,  108,  0,
    6,  -250, 0,    12, 150,  0,    17, 0,     -513,  1,  50,    0,     6,  300,   741,   12, 200,  -1412,
    17, -50,  -625, 1,  0,    0,    17, 0,     0,     1,  0,     0,     7,  -450,  -2069, 11, -600, 0,
    17, -450, 591,  1,  150,  0,    7,  -300,  0,     11, 0,     0,     17, -50,   0,     1,  -200, 0,
    7,  50,   0,    11, -200, 0,    17, 0,     495,   1,  0,     0,     17, 0,     0,     1,  -480, 0,
    6,  -700, 0,    11, -600, 1478, 17, -200,  0,     1,  0,     0,     17, 0,     0,     1,  0,    0,
    5,  406,  3192, 17, 850,  0,    1,  150,   0,     5,  200,   0,     11, -250,  0,     14, -150, 0,
    17, -150, 0,    1,  250,  0,    5,  50,    -2567, 11, -200,  0,     17, -138,  467,   1,  0,    0,
    17, 0,    0,    1,  -971, 0,    5,  -400,  3153,  11, -200,  0,     17, -400,  -1691, 1,  0,    0,
    17, 0,    0,    1,  920,  0,    5,  600,   0,     9,  965,   0,     13, 67,    -3418, 15, -45,  -1157,
    17, -104, -800, 1,  0,    0,    5,  -173,  0,     9,  -26,   1759,  13, 299,   -528,  16, 345,  1132,
    17, 386,  1414, 1,  -135, 0,    5,  398,   0,     9,  109,   -2079, 13, -70,   -1171, 17, -181, -814,
    1,  -58,  0,    7,  -40,  288,  13, 50,    311,   17, 60,    -123,  1,  68,    0,     7,  250,  499,
    13, 300,  481,  17, 400,  482,  1,  0,     0,     7,  -200,  0,     13, 0,     669,   17, 0,    -147,
    1,  0,    0,    17, 0,    0,    1,  0,     0,     17, 0,     0,     1,  0,     0,     17, 0,    0
};

u8 npc_1_kokeru10_tex_index[] = { 3, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5 };

u8 npc_1_kokeru11_tex_index[] = { 0, 1, 2, 2, 6, 6, 6, 6, 1, 7, 7, 7, 7, 7, 7, 7, 7 };

static int lfoot_se_chk_pat[] = { 2 };

static aNPC_se_data_c lfoot_se_dt[] = { { ARRAY_COUNT(lfoot_se_chk_pat), lfoot_se_chk_pat } };

static aNPC_se_data_table_c se_dt_tbl[] = { { lfoot_se_dt, NULL, aNPC_OTHER_SE_TYPE_NONE, NULL } };

aNPC_Animation_c cKF_ba_r_npc_1_kokeru1 = {
    { cKF_ckcb_r_npc_1_kokeru1_tbl, cKF_ds_npc_1_kokeru1_tbl, cKF_kn_npc_1_kokeru1_tbl, cKF_c_npc_1_kokeru1_tbl, -1,
      17 },
    1.0f,
    17.0f,
    cKF_FRAMECONTROL_STOP,
    -5.0f,
    npc_1_kokeru11_tex_index,
    aNPC_EYE_TEX0,
    -1,
    npc_1_kokeru10_tex_index,
    aNPC_MOUTH_TEX0,
    -1,
    -1,
    -1,
    NULL,
    se_dt_tbl,
};
