mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-08 04:21:50 +00:00
Block animation
This commit is contained in:
parent
fa6eb6ae22
commit
5fb34daf52
9 changed files with 264 additions and 24 deletions
|
|
@ -54,6 +54,14 @@ void Assets::store(Atlas* atlas, std::string name){
|
|||
atlases[name].reset(atlas);
|
||||
}
|
||||
|
||||
const std::vector<TextureAnimation>& Assets::getAnimations() {
|
||||
return animations;
|
||||
}
|
||||
|
||||
void Assets::store(const TextureAnimation& animation) {
|
||||
animations.emplace_back(animation);
|
||||
}
|
||||
|
||||
void Assets::extend(const Assets& assets) {
|
||||
for (auto entry : assets.textures) {
|
||||
textures[entry.first] = entry.second;
|
||||
|
|
@ -67,4 +75,7 @@ void Assets::extend(const Assets& assets) {
|
|||
for (auto entry : assets.atlases) {
|
||||
atlases[entry.first] = entry.second;
|
||||
}
|
||||
for (auto entry : assets.animations) {
|
||||
animations.emplace_back(entry);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue