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

s16 cKF_c_npc_1_ha_d2_tbl[] = { 2400, 0,    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_ha_d2_tbl[] = {
    1,  0,    0,    9,  0,    0,    1,  0,    0,    31, 0,    0,    1,  80,   0,    16, 105,  0,    31, 80,   0,
    1,  0,    0,    31, 0,    0,    1,  -750, 150,  7,  -730, 0,    23, -770, 0,    31, -750, 146,  1,  -500, -103,
    5,  -510, 0,    21, -480, 0,    31, -500, -101, 1,  300,  148,  7,  320,  0,    23, 270,  0,    31, 300,  148,
    1,  0,    0,    31, 0,    0,    1,  350,  305,  7,  400,  0,    23, 300,  0,    31, 350,  296,  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,  750,  -147, 7,  730,  0,    23, 770,  0,    31, 750,  -149, 1,  -500, -102, 5,  -510, 0,    21, -480, 0,
    31, -500, -101, 1,  -300, -148, 7,  -320, 0,    23, -270, 0,    31, -300, -150, 1,  0,    0,    31, 0,    0,
    1,  350,  302,  7,  400,  0,    23, 300,  0,    31, 350,  297,  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,  -250, 0,    31, -250, 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,  -50,  -101, 5,  -60,  0,
    16, -40,  61,   25, -35,  -50,  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,  -250, 0,    31, -250, 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,  -250, 0,
    31, -250, 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,  0,    0,    31, 0,    0,    1,  0,    0,    31, 0,    0
};

aNPC_Animation_c cKF_ba_r_npc_1_ha_d2 = {
    { cKF_ckcb_r_npc_1_ha_d2_tbl, cKF_ds_npc_1_ha_d2_tbl, cKF_kn_npc_1_ha_d2_tbl, cKF_c_npc_1_ha_d2_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,
};
