- [NEW] Càrrega i pintat d'enemics en l'habitació
This commit is contained in:
26
source/enemies.h
Normal file
26
source/enemies.h
Normal file
@@ -0,0 +1,26 @@
|
||||
#pragma once
|
||||
#include "images.h"
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace enemies
|
||||
{
|
||||
struct animation_t
|
||||
{
|
||||
std::string name {""};
|
||||
float speed {0.0f};
|
||||
uint8_t loop {0};
|
||||
std::vector<uint8_t> frames;
|
||||
};
|
||||
|
||||
struct enemy_t
|
||||
{
|
||||
draw::surface *tileSetFile {nullptr};
|
||||
uint8_t frame_width {0};
|
||||
uint8_t frame_height {0};
|
||||
std::vector<animation_t> animations;
|
||||
};
|
||||
|
||||
void load();
|
||||
enemy_t &get(std::string name);
|
||||
}
|
||||
Reference in New Issue
Block a user