BIG MOVES
This commit is contained in:
54
semestralka1/src/assets/character_frames.h
Normal file
54
semestralka1/src/assets/character_frames.h
Normal file
@@ -0,0 +1,54 @@
|
||||
// src/assets/character_frames.h
|
||||
|
||||
#pragma once
|
||||
|
||||
// Player frame 1
|
||||
static const char *CHARACTER_MASK_FRAME_1[] = {
|
||||
".....a@$..",
|
||||
".....7PF..",
|
||||
"..yaM@@__y",
|
||||
"..@.y@FFF~",
|
||||
"..._$M@_..",
|
||||
"yaa@~.`@y.",
|
||||
"........@r"
|
||||
};
|
||||
|
||||
// Player frame 2
|
||||
static const char *CHARACTER_MASK_FRAME_2[] = {
|
||||
".g@$",
|
||||
".7PF",
|
||||
"y@$.",
|
||||
"0@F.",
|
||||
"4@$.",
|
||||
"y$@.",
|
||||
"u@.."
|
||||
};
|
||||
|
||||
// Player frame 3 (triggered)
|
||||
static const char *CHARACTER_MASK_FRAME_3[] = {
|
||||
".._$@.",
|
||||
".$By`.",
|
||||
"4@$@@a",
|
||||
"aa@W@."
|
||||
};
|
||||
|
||||
enum class CharacterFrame {
|
||||
Walk1 = 0,
|
||||
Walk2,
|
||||
Crawl1,
|
||||
COUNT // number of frames, must stay last
|
||||
};
|
||||
|
||||
// Combine frames for easy access
|
||||
static const char **PLAYER_FRAMES[] = {
|
||||
CHARACTER_MASK_FRAME_1, // Walk1
|
||||
CHARACTER_MASK_FRAME_2, // Walk1
|
||||
CHARACTER_MASK_FRAME_3 // Crawl1
|
||||
};
|
||||
|
||||
static const int CHARACTER_FRAME_COUNT = static_cast<int>(CharacterFrame::COUNT);
|
||||
|
||||
// Height per frame
|
||||
static const int CHARACTER_HEIGHT_1 = sizeof(CHARACTER_MASK_FRAME_1) / sizeof(CHARACTER_MASK_FRAME_1[0]);
|
||||
static const int CHARACTER_HEIGHT_2 = sizeof(CHARACTER_MASK_FRAME_2) / sizeof(CHARACTER_MASK_FRAME_2[0]);
|
||||
static const int CHARACTER_HEIGHT_3 = sizeof(CHARACTER_MASK_FRAME_3) / sizeof(CHARACTER_MASK_FRAME_3[0]);
|
||||
Reference in New Issue
Block a user