playMaker

Author Topic: Stop an action mid action  (Read 175 times)

FoxShady

  • Playmaker Newbie
  • *
  • Posts: 2
Stop an action mid action
« on: December 13, 2022, 12:59:15 AM »
Hello!

Starting off by saying that I am in love with playmaker. Really helps my visual brain see my logic work. One snag I found myself into recently is the fact that my move towards action can't be interrupted. Let me explain.
So I want to get a character to move to a place where I click, kinda like in an RTS or a MOBA. I eventually got it down with the Move towards option on a point that I set from another FSM that I send forward. The problem is that I can't interrupt the action once it starts. I have to wait for it to send another event. I want to be able to click on another part of the map instantly and have the character immediately snap toward that location even if it moving during its action sequence. Is there a way to kill an action or reset a state once an event triggers it?
Still trying to get the hang of all of the actions I can do with this thing so my bad if this has already been solved or there is an easy solution to this that I didn't see.

Any help is appreciated!

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7169
    • jinxtergames
Re: Stop an action mid action
« Reply #1 on: December 13, 2022, 07:54:44 AM »
Hi
You can for example use a global transition to a different state


FoxShady

  • Playmaker Newbie
  • *
  • Posts: 2
Re: Stop an action mid action
« Reply #2 on: December 14, 2022, 04:31:14 PM »
So I got it fixed. I knew it had to be something with global transitions and the way I was using them. It turned out that I needed to just place it on a different state. It works perfectly fine now. Thanks for the assistance!