playMaker

Author Topic: Code Flow in Playmaker  (Read 1696 times)

miguelfanclub

  • Full Member
  • ***
  • Posts: 165
Code Flow in Playmaker
« on: February 07, 2018, 06:41:44 AM »
A trivial question but to be very sure:

- A state with several actions inside:

-- Action 1
-- Action 2
-- Action 3 (send global event)
-- Action 4

Does the action 4 starts when global event from action 3 is finished?
If that global event fired fires another global event will occur the same?
Is there a way to put a breakpoint in an action rather than a state?




jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Code Flow in Playmaker
« Reply #1 on: February 08, 2018, 04:17:45 AM »
Hi,

Good question indeed.

Action 4 will be executed when Action has been called, regardless of it's finished state.

I don't get your second question, but I think the answer is that yes, it will occur in the same frame and code stack of execution.

No way to put a breakpoint on action, it's per state. So move Action 4 into a new state following the current state, then you can breakpoint on action 4, and the process will be identical in terms of execution flow.

NOW, a state has an option to be "sequential" which means each action will wait for the previous action to have finished, and so in that case, Action 4 would only be executed after Action 3 has called finished.

 Bye,

 Jean

miguelfanclub

  • Full Member
  • ***
  • Posts: 165
Re: Code Flow in Playmaker
« Reply #2 on: February 09, 2018, 04:49:38 AM »
Thanks.

Can you tell me how to create a sequential state?
With this, Action 4 in my example, will only start once the global event sent by action 3 is finished, right?

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Code Flow in Playmaker
« Reply #3 on: February 09, 2018, 05:10:50 AM »