PlayMaker Feedback > Action Requests

Sequencing actions

<< < (2/2)

MaDDoX:

--- Quote from: yannalaplage on April 25, 2011, 05:27:17 PM ---a lot of the fragmentation to an FSM is due to the lack of sequencing btw actions, they all occurs at the same time. if that make sense regarding "state" that also makes lots of spaghetti ;)
--- End quote ---

Wait a minute here, who said all actions in the action list of a state happen at the same time? I'm quite sure they're executed sequentially, for instance, whenever I stack up actions like "send message" and "destroy", destroy is NEVER called before the message is sent. There's also a mini-highlight (I guess in yellow color) for the specific action being executed during a state.

So if Playmaker has been fooling me all this time, please explain why/how :)

jasonlee:
MaDDoX is right, the actions are executed sequentially. But, some action could also be executed on every frame, that might brings some confusion in some situation.

Eg, I have 4 actions:

action 1, run once;
action 2, run on every frame;
action 3, run once;
action 4, run on every frame;

Then, on frame 1 after enter the state, the execution flow:

action 1 -> action 2 -> action 3 -> action 4

On frame 2 and after:

action 2 -> action 4

If action 1 and action 2 both access some external variable, and action 2 reading output from action 1, you might wonder why action 2 not behave properly until you realize you also should tick "every frame" on action 1.

Navigation

[0] Message Index

[*] Previous page

Go to full version