mirror of
https://github.com/wesnoth/wesnoth
synced 2025-04-30 11:37:47 +00:00
wesnoth.create_animator: Set standing right after animation completed rather than at finalization
This commit is contained in:
parent
c3e0ce4745
commit
16df1f3c43
@ -337,7 +337,6 @@ static const char animatorKey[] = "unit animator";
|
|||||||
|
|
||||||
static int impl_animator_collect(lua_State* L) {
|
static int impl_animator_collect(lua_State* L) {
|
||||||
unit_animator& anim = *static_cast<unit_animator*>(luaL_checkudata(L, 1, animatorKey));
|
unit_animator& anim = *static_cast<unit_animator*>(luaL_checkudata(L, 1, animatorKey));
|
||||||
anim.set_all_standing();
|
|
||||||
anim.~unit_animator();
|
anim.~unit_animator();
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@ -438,6 +437,7 @@ static int impl_run_animation(lua_State* L)
|
|||||||
unit_animator& anim = *static_cast<unit_animator*>(luaL_checkudata(L, 1, animatorKey));
|
unit_animator& anim = *static_cast<unit_animator*>(luaL_checkudata(L, 1, animatorKey));
|
||||||
anim.start_animations();
|
anim.start_animations();
|
||||||
anim.wait_for_end();
|
anim.wait_for_end();
|
||||||
|
anim.set_all_standing();
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user