(using urho3d from git, w7 x64)
Animation that comes with Urho3D, works right when flipping.
But when I try to flip my own animation, crash.
AnimatedSprite2D* animatedSprite = playerNode->GetComponent<AnimatedSprite2D>();
if (input->GetKeyDown(KEY_LEFT))
animatedSprite->SetFlipX(true);
It crashes on AnimatedSprite2D.cpp at OnFlipChanged() method
void AnimatedSprite2D::OnFlipChanged()
{
for (unsigned i = 0; i < numTracks_; ++i)
{
if (!trackNodes_[i])
continue;
StaticSprite2D* staticSprite = trackNodes_[i]->GetComponent<StaticSprite2D>();
staticSprite->SetFlip(flipX_, flipY_); /////<<<<<<<<<<<--------- when i==3, staticSprite==null
}
// For editor paused mode
UpdateAnimation(0.0f);
}
Tried “key all” in Spiter, doesnt help. Dont know how I must setup my character that it works right.
Here is my stupid character+anim (you can use whatever images) in case someone wants try it out
ukko2.scml
Remember this is open source so patches don’t need to be made to the current version like in most commercial software like Unity.
Just download the latest source (also called HEAD).
So much has changed since its release…
So much has changed since its release…[/quote]