#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_ha2_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_ha2_tbl[] = { 2, 2, 2, 2, 3, 2, 2, 3, 2, 2, 3, 2, 2, 2, 2, 2, 3, 2, 2, 3, 2, 2, 2, 2, 2, 5, 2,
                               2, 5, 2, 2, 5, 2, 2, 2, 3, 2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 2, 2, 2, 5, 3, 2, 3, 2 };

s16 cKF_c_npc_1_ha2_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_ha2_tbl[] = {
    1,  0,    0,   31, 0,    0,    1,  1025, 0,    31, 1025, 0,    1,  -100, 0,   31, -100, 0,    1,  0,    0,
    31, 0,    0,   1,  30,   0,    16, 55,   0,    31, 30,   0,    1,  0,    0,   31, 0,    0,    1,  -175, 0,
    31, -175, 0,   1,  -60,  0,    15, -25,  0,    31, -60,  0,    1,  25,   0,   31, 25,   0,    1,  0,    0,
    31, 0,    0,   1,  100,  0,    15, 50,   0,    31, 100,  0,    1,  0,    0,   31, 0,    0,    1,  0,    0,
    31, 0,    0,   1,  -100, 0,    31, -100, 0,    1,  0,    0,    31, 0,    0,   1,  175,  0,    31, 175,  0,
    1,  -60,  0,   15, -25,  0,    31, -60,  0,    1,  -25,  0,    31, -25,  0,   1,  0,    0,    31, 0,    0,
    1,  100,  0,   15, 50,   0,    31, 100,  0,    1,  0,    0,    31, 0,    0,   1,  0,    0,    31, 0,    0,
    1,  -100, 0,   31, -100, 0,    1,  0,    0,    31, 0,    0,    1,  0,    0,   31, 0,    0,    1,  -260, -404,
    8,  -300, 0,   16, -250, 490,  24, -200, 0,    31, -250, -509, 1,  0,    0,   31, 0,    0,    1,  0,    0,
    31, 0,    0,   1,  20,   -511, 9,  -50,  0,    17, 10,   451,  25, 70,   0,   31, 20,   -513, 1,  0,    0,
    31, 0,    0,   1,  0,    0,    31, 0,    0,    1,  50,   -101, 5,  40,   0,   16, 60,   62,   22, 68,   0,
    31, 50,   -98, 1,  0,    0,    31, 0,    0,    1,  -200, 0,    31, -200, 0,   1,  -100, 0,    31, -100, 0,
    1,  -600, 0,   16, -570, 0,    31, -600, 0,    1,  0,    0,    31, 0,    0,   1,  -110, 0,    31, -110, 0,
    1,  0,    0,   31, 0,    0,    1,  200,  0,    31, 200,  0,    1,  -100, 0,   31, -100, 0,    1,  600,  0,
    16, 570,  0,   31, 600,  0,    1,  0,    0,    31, 0,    0,    1,  -110, 0,   31, -110, 0,    1,  0,    0,
    31, 0,    0,   1,  0,    0,    31, 0,    0,    1,  0,    0,    31, 0,    0,   1,  0,    0,    31, 0,    0,
    1,  0,    0,   31, 0,    0,    1,  30,   -112, 11, 10,   0,    21, 30,   123, 26, 40,   0,    31, 30,   -108,
    1,  5,    0,   16, -5,   0,    31, 5,    0,    1,  0,    0,    31, 0,    0,   1,  -150, 0,    15, -125, 0,
    31, -150, 0,   1,  0,    0,    31, 0,    0
};

aNPC_Animation_c cKF_ba_r_npc_1_ha2 = {
    { cKF_ckcb_r_npc_1_ha2_tbl, cKF_ds_npc_1_ha2_tbl, cKF_kn_npc_1_ha2_tbl, cKF_c_npc_1_ha2_tbl, -1, 31 },
    1.0f,
    31.0f,
    cKF_FRAMECONTROL_REPEAT,
    0.0f,
    NULL,
    aNPC_EYE_TEX0,
    6,
    NULL,
    aNPC_MOUTH_TEX2,
    4,
    -1,
    -1,
    NULL,
    NULL,
};
