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

s16 cKF_c_npc_1_ready1_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_ready1_tbl[] = {
    1,  0,    0,    41, 0,    0,    1,  750,  0,   21, 700,  0,    41, 750,  0,   1,  0,    0,    21, 25,   0,
    41, 0,    0,    1,  -450, 0,    41, -450, 0,   1,  0,    0,    21, -20,  0,   41, 0,    0,    1,  0,    0,
    41, 0,    0,    1,  -340, 0,    21, -325, 0,   41, -340, 0,    1,  -350, 0,   21, -400, 0,    41, -350, 0,
    1,  375,  0,    21, 400,  0,    41, 375,  0,   1,  0,    0,    41, 0,    0,   1,  865,  0,    21, 975,  0,
    41, 865,  0,    1,  0,    0,    41, 0,    0,   1,  0,    0,    41, 0,    0,   1,  -370, 0,    21, -450, 0,
    41, -370, 0,    1,  -175, 0,    21, -200, 0,   41, -175, 0,    1,  -85,  0,   21, -110, 0,    41, -85,  0,
    1,  175,  0,    21, 170,  0,    41, 175,  0,   1,  -515, 0,    21, -530, 0,   41, -515, 0,    1,  0,    0,
    41, 0,    0,    1,  325,  0,    21, 350,  0,   41, 325,  0,    1,  0,    0,   41, 0,    0,    1,  -130, 0,
    21, -158, 0,    41, -130, 0,    1,  -150, 0,   21, -158, 0,    41, -150, 0,   1,  600,  0,    21, 645,  0,
    41, 600,  0,    1,  0,    0,    41, 0,    0,   1,  -41,  -145, 13, -75,  0,   23, -50,  151,  33, -25,  0,
    41, -41,  -134, 1,  24,   49,   3,  25,   0,   23, -28,  0,    41, 24,   63,  1,  0,    0,    41, 0,    0,
    1,  75,   -343, 6,  0,    -602, 16, -100, 0,   26, 0,    605,  36, 100,  0,   41, 75,   -343, 1,  68,   325,
    6,  100,  0,    26, -110, 0,    41, 68,   325, 1,  -50,  0,    3,  -50,  0,   23, -25,  0,    41, -50,  0,
    1,  -270, 0,    3,  -270, 0,    23, -300, 0,   41, -270, 0,    1,  -113, 40,  13, -100, 0,    33, -120, 0,
    41, -113, 44,   1,  -310, 149,  5,  -300, 0,   25, -410, 0,    41, -310, 149, 1,  -498, -37,  5,  -500, 0,
    25, -480, 0,    41, -498, -37,  1,  -10,  154, 5,  0,    0,    25, -100, 0,   41, -10,  154,  1,  0,    0,
    41, 0,    0,    1,  -323, 194,  7,  -300, 0,   27, -400, 0,    41, -323, 194, 1,  0,    0,    41, 0,    0,
    1,  48,   75,   3,  50,   0,    23, 0,    0,   41, 48,   75,   1,  490,  0,   3,  490,  0,    23, 480,  0,
    41, 490,  0,    1,  303,  -75,  3,  300,  0,   23, 400,  0,    41, 303,  -75, 1,  0,    0,    41, 0,    0,
    1,  -315, 225,  5,  -300, 0,    25, -450, 0,   41, -315, 225,  1,  0,    0,   41, 0,    0,    1,  0,    0,
    41, 0,    0,    1,  0,    0,    41, 0,    0,   1,  0,    0,    41, 0,    0,   1,  508,  38,   5,  510,  0,
    25, 490,  0,    41, 508,  38,   1,  123,  -38, 5,  120,  0,    25, 150,  0,   41, 123,  -38,  1,  -8,   -37,
    5,  -10,  0,    25, 10,   0,    41, -8,   -37, 1,  0,    0,    41, 0,    0,   1,  0,    0,    41, 0,    0,
    1,  0,    0,    41, 0,    0
};

aNPC_Animation_c cKF_ba_r_npc_1_ready1 = {
    { cKF_ckcb_r_npc_1_ready1_tbl, cKF_ds_npc_1_ready1_tbl, cKF_kn_npc_1_ready1_tbl, cKF_c_npc_1_ready1_tbl, -1, 41 },
    1.0f,
    41.0f,
    cKF_FRAMECONTROL_REPEAT,
    -5.0f,
    NULL,
    aNPC_EYE_TEX0,
    0,
    NULL,
    aNPC_MOUTH_TEX2,
    3,
    -1,
    -1,
    NULL,
    NULL,
};
