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

s16 cKF_c_npc_1_musu_r1_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_musu_r1_tbl[] = {
    1,  0,    0,    33, 0,    0,   1,  0,    0,    17, 100,  0,    33, 0,    0,    1,  0,    0,    17, -50,  0,
    33, 0,    0,    1,  0,    0,   33, 0,    0,    1,  50,   0,    17, 25,   0,    33, 50,   0,    1,  0,    0,
    33, 0,    0,    1,  0,    0,   33, 0,    0,    1,  0,    0,    33, 0,    0,    1,  0,    0,    33, 0,    0,
    1,  0,    0,    33, 0,    0,   1,  0,    0,    33, 0,    0,    1,  0,    0,    33, 0,    0,    1,  0,    0,
    33, 0,    0,    1,  0,    0,   33, 0,    0,    1,  0,    0,    33, 0,    0,    1,  0,    0,    33, 0,    0,
    1,  0,    0,    33, 0,    0,   1,  0,    0,    33, 0,    0,    1,  0,    0,    33, 0,    0,    1,  0,    0,
    33, 0,    0,    1,  0,    0,   33, 0,    0,    1,  0,    0,    33, 0,    0,    1,  0,    0,    33, 0,    0,
    1,  0,    0,    33, 0,    0,   1,  0,    0,    33, 0,    0,    1,  0,    0,    33, 0,    0,    1,  0,    0,
    33, 0,    0,    1,  0,    0,   33, 0,    0,    1,  0,    0,    33, 0,    0,    1,  0,    0,    33, 0,    0,
    1,  0,    0,    33, 0,    0,   1,  -50,  0,    2,  -50,  0,    10, -65,  -171, 17, -80,  0,    18, -80,  0,
    26, -65,  168,  33, -50,  0,   1,  0,    171,  9,  20,   0,    17, 0,    -152, 25, -20,  0,    32, -5,   134,
    33, 0,    173,  1,  0,    0,   33, 0,    0,    1,  -53,  72,   3,  -50,  0,    19, -100, 0,    33, -53,  72,
    1,  -270, -462, 11, -400, 0,   27, -210, 0,    33, -270, -445, 1,  140,  -331, 12, 20,   0,    28, 175,  0,
    33, 140,  -331, 1,  -693, 185, 12, -640, 0,    28, -710, 0,    33, -693, 185,  1,  -115, 724,  12, 115,  0,
    28, -183, 0,    33, -115, 724, 1,  403,  -73,  3,  400,  0,    19, 450,  0,    33, 403,  -73,  1,  -548, -73,
    3,  -550, 0,    19, -500, 0,   33, -548, -73,  1,  98,   75,   3,  100,  0,    19, 50,   0,    33, 98,   75,
    1,  0,    0,    33, 0,    0,   1,  -793, -106, 4,  -800, 0,    20, -750, 0,    33, -793, -106, 1,  0,    0,
    33, 0,    0,    1,  -545, 459, 11, -455, 0,    27, -600, 0,    33, -545, 459,  1,  293,  -576, 3,  250,  -766,
    11, 150,  0,    19, 250,  746, 27, 350,  0,    33, 293,  -576, 1,  -500, 833,  11, -300, 0,    27, -600, 0,
    33, -500, 840,  1,  -10,  121, 3,  0,    171,  11, 20,   0,    19, 0,    -152, 27, -20,  0,    33, -10,  121,
    1,  -51,  37,   3,  -50,  0,   11, -65,  -129, 19, -80,  0,    27, -65,  127,  33, -51,  37,   1,  0,    0,
    33, 0,    0,    1,  0,    0,   10, 0,    0,    13, 0,    0,    16, 0,    0,    19, 0,    0,    22, 0,    0,
    33, 0,    0,    1,  0,    0,   10, 0,    0,    13, 100,  0,    16, -50,  0,    19, 100,  0,    22, 0,    0,
    33, 0,    0,    1,  0,    0,   10, 0,    0,    13, -30,  0,    16, 0,    0,    19, 30,   0,    22, 0,    0,
    33, 0,    0
};

aNPC_Animation_c cKF_ba_r_npc_1_musu_r1 = {
    { cKF_ckcb_r_npc_1_musu_r1_tbl, cKF_ds_npc_1_musu_r1_tbl, cKF_kn_npc_1_musu_r1_tbl, cKF_c_npc_1_musu_r1_tbl, -1,
      33 },
    1.0f,
    33.0f,
    cKF_FRAMECONTROL_REPEAT,
    -5.0f,
    NULL,
    aNPC_EYE_TEX0,
    4,
    NULL,
    aNPC_MOUTH_TEX1,
    0,
    -1,
    -1,
    NULL,
    NULL,
};
