2.
You do have 5 kinds of events.
An event that sets new states.
An event that starts things up when entering the state. <--- a trigger
An event that stop things when leaving the state. <-- a trigger
An event that maintains code when in that state <----- got to check those every tick
Restraining of events that are only allowed to run when in a certain state
Set a new state < an action under a condition that decides the change
The condition can be anything, a key press, a overlap with an object .... virtual any thing. Now the state is set. And the triggers in the plugin will catch that 'change of state'. So .....
On enter (state)
Anything that we want to happen only once when entering this state goes under this condition. Like changing an animation. Play a sound ..... etc
On exit (state)
Anything that we only once want to happen on exit. Like reversing an animation, stopping a sound from playing.
An event that maintains code for that state /
Anything that needs to be tested every tick as long as we are in that state goes here. Like a continuous checking if the player is overlapping a door.
Typical this starts with a condition like
System > Compare 2 values FSM.CurState = "StartPoint" (are we still in the right state ?)
Restraining of events that are only allowed to run when in a certain state
A 'on key pressed' is a trigger. A trigger should (not a rule, just what i think is good practice) always be the first condition in a root event. But then we need to constrain that trigger from running its events when not in the right state. Or assign actions depending on the state. That is typical something like, when assigning actions .....
On key pressed (up arrow) <--------- root condition
___System > Compare 2 values FSM.CurState = "StartPoint" <---- sub condition
__________ action simulate 8 direction go up
___System > Compare 2 values FSM.CurState = "InGame"
__________ action simulate platform jump
Or when just constraining a trigger
On function "Play"
System > Compare 2 values FSM.CurState = "StartPoint" (are we still in the right state ?)
____Play (by name) use the function parameters to fill in the info
Hope this general approach will help you.