playMaker

Author Topic: Remain in a state while animation plays[SOLVED]  (Read 1601 times)

spalamas

  • Playmaker Newbie
  • *
  • Posts: 2
Remain in a state while animation plays[SOLVED]
« on: February 27, 2020, 03:28:21 AM »
Goodmorning.

I'm new in Playmaker. I searched with "animation" in the forum and didn't find a previous solution so I would like to ask this:
I have a character which should cycle between a set of animations. So I made an FSM with a state for each animation and on each state I placed an "animator play" action to play the animation I want. THe problem is that since the animation starts the FSM moves to the next state before finishing the animation. Is there a way to remain in the specific state until the animation finishes? I found myself a solution placing a "wait" action on each state after the animator play to wait there for so many seconds as the animastion lasts but I would prefer an autoimatic solution. Wait on the state until the animation finishes and then move on to next state.

Thank you!
« Last Edit: March 02, 2020, 06:21:03 AM by jeanfabre »

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7616
    • jinxtergames
Re: Remain in a state while animation plays
« Reply #1 on: February 27, 2020, 04:27:14 AM »
Hi.
I made a custom action as i could not find any on the Ecosystem

You can find it in the attachment below.

Please let me know if it works good, so i can place on the Ecosystem :)

Broken Stylus

  • Beta Group
  • Hero Member
  • *
  • Posts: 773
Re: Remain in a state while animation plays
« Reply #2 on: February 28, 2020, 02:23:54 PM »
Does it wait for the animation to be finished to send an event?

spalamas

  • Playmaker Newbie
  • *
  • Posts: 2
Re: Remain in a state while animation plays
« Reply #3 on: February 29, 2020, 05:24:14 AM »
Hi.
I made a custom action as i could not find any on the Ecosystem

You can find it in the attachment below.

Please let me know if it works good, so i can place on the Ecosystem :)

Thank you very musch for your fast response. I'm sorry I didn't have the time to test earlier. It works like a charm! Thank you again! I'll discard so many "waits" :-)

Since you are so kind I will take advantage of you :-) Could you please make the same for timelines? The "Play Timeline" has exactly the same problem ! It will start playing and move on. It would be nice to be able to stay there until animation finishes. I use "wait" now.