RedcrowProd
Member
|
RE: How can I get AnimatedSkeleton from Extended Game.Item
Hi,
Yes there is, like i pointed it out before, in the exact same tutorial you were using, there is motion being set and used there.
if(Ms.bp(0))
{
MyMotion.set(obj.skel, AnimationAbility);
}
then you can do in update
MyMotion.updateAuto(1, 1);
|
|
06-27-2020 10:01 PM |
|
tipforeveryone
Bronze Supporter
|
RE: How can I get AnimatedSkeleton from Extended Game.Item
|
|
06-28-2020 10:42 AM |
|
Otolone
Member
|
RE: How can I get AnimatedSkeleton from Extended Game.Item
Code:
class Weapon
{
Memc<Motion> reload_motions;
void animate()
{
REPA( reload_motions)skel.animate( reload_motions[i], true); // apply reload animations
}
bool update()
{
if(kb.b(KB_ENTER)
{
reload_motions.New().set(skelOfGun, "gun animation"); // add animation to container
}
// update all motion animations
REPA(reload_motions)
{
if(!reload_motions[i].updateAuto(3, 3, 0.5))
{
reload_motions.remove(i); // remove motion after it has finished playing
}
}
}
}
I hope that helps!
|
|
04-28-2021 04:00 AM |
|