Everyone has different animations, but they tend to cancel each other out. Need to refine it next.
This commit is contained in:
parent
458bf7e25e
commit
ba91929bfd
5 changed files with 19 additions and 11 deletions
|
|
@ -120,9 +120,13 @@ namespace scene {
|
|||
config.pos = position_sprite(config.st, config.cell, config.scale, config.at_mid);
|
||||
}
|
||||
|
||||
void Engine::animate_actor(const std::string& actor) {
|
||||
void Engine::animate_actor(const std::string& actor, const std::string& form) {
|
||||
auto& config = actor_config(actor);
|
||||
if(!config.anim.playing) config.anim.play();
|
||||
|
||||
if(!config.anim.playing) {
|
||||
config.anim.play();
|
||||
config.anim.set_form(form);
|
||||
}
|
||||
}
|
||||
|
||||
inline void this_is_stupid_refactor(std::vector<Element>& elements) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue