#pragma once

#define TEX_GROUND         0
#define TEX_KNIGHT         1
#define TEX_MOUSE_CURSOR   2
#define TEX_TARGET_RETICLE 3

#define ANIM_KNIGHT_IDLE         0
#define ANIM_KNIGHT_RUN          1
#define ANIM_KNIGHT_ATTACK_SIDE1 2
#define ANIM_KNIGHT_ATTACK_SIDE2 3
#define ANIM_KNIGHT_ATTACK_TOP1  4
#define ANIM_KNIGHT_ATTACK_TOP2  5
#define ANIM_KNIGHT_ATTACK_BACK1 6
#define ANIM_KNIGHT_ATTACK_BACK2 7

// SpriteSheet knight_spritesheet = {
//     .name = "blue_knight",
//     .texture = {0},
//     // .anim_count = 8,
//     .size = { 1152, 1536 },
// };

const u16 knight_sprite_size = 192;
const Vector2 knight_origin = {knight_sprite_size / 2, knight_sprite_size / 2 + 35};
const Size knight_col_size = {50, 75};
// TODO: We probably want this as a helper function somewhere
const Rectangle knight_colrect_select = {
    -knight_col_size.width / 2,
    -knight_col_size.height / 2 - 35,
    knight_col_size.width,
    knight_col_size.height,
};

SpriteAnimation knight_idle = {
    .loop = true,
    .total_frames = 6,
};

SpriteAnimation knight_run = {
    .loop = true,
    .total_frames = 6,
};

SpriteAnimation knight_attack_side1 = {
    .loop = false,
    .total_frames = 6,
};

SpriteAnimation knight_attack_side2 = {
    .loop = false,
    .total_frames = 6,
};

SpriteAnimation knight_attack_front1 = {
    .loop = false,
    .total_frames = 6,
};

SpriteAnimation knight_attack_front2 = {
    .loop = false,
    .total_frames = 6,
};

SpriteAnimation knight_attack_back1 = {
    .loop = false,
    .total_frames = 6,
};

SpriteAnimation knight_attack_back2 = {
    .loop = false,
    .total_frames = 6,
};

SpriteAnimation knight_anims[8];
// knight_anims[ANIM_KNIGHT_IDLE] = knight_idle;
// knight_anims[ANIM_KNIGHT_RUN] = knight_run;
// knight_anims[ANIM_KNIGHT_ATTACK_SIDE1] = knight_attack_side1;
// knight_anims[ANIM_KNIGHT_ATTACK_SIDE2] = knight_attack_side2;
// knight_anims[ANIM_KNIGHT_ATTACK_TOP1] = knight_attack_front1;
// knight_anims[ANIM_KNIGHT_ATTACK_TOP2] = knight_attack_front2;
// knight_anims[ANIM_KNIGHT_ATTACK_BACK1] = knight_attack_back1;
// knight_anims[ANIM_KNIGHT_ATTACK_BACK2] = knight_attack_back2;
