lasttime
us used for events (and any maybe attachments).
Sorry I kinda assumed you changed your flow for this. and wanted to set the animation everyframe. We do this for loading bars and it works well.
you have to remember that spine doesn't work in frames to- it works in time, frames are just nicer numbers to work with. if you apsolutly need it to stop frame perfect, for what ever reason. When you update your skeleton, instead of passing in delta time, you could pass in a set value(0.0333).
This is what we use for bars loading and unloading:
float CurrentFrame = mesh->GetFrameCurrentAnim(track);
int32_t dur = mesh->GetNumFramesCurrentAnim(track);
float frameToSetTo = ratio * dur;
const char * animToPlay = LoadAnimname;
if (CurrentFrame > -1 && CurrentFrame > frameToSetTo)
{
animToPlay = UnLoadanimname;
frameToSetTo = (1-ratio) * dur; // inverse the ratio
}
if (Str.Cmp(mesh->GetCurrentAnim(track),animToPlay)!=0)
{
mesh->SetAnim(animToPlay,false,track);
}
mesh->AnimPause(track);
mesh->SetFrameCurrentAnim(frameToSetTo, track);
again this isn't letting the animation "play to a point", but as we calculate where in the animation the bar should be filled up from every frame, it doesn't really matter - for us anyway.
sorry if this isn't clear. :beer: :drunk: :puke: :puke: :puke: :puke: