playMaker

Author Topic: Set Event Data and Get Event Info  (Read 3854 times)

szomaza

  • Sr. Member
  • ****
  • Posts: 253
Set Event Data and Get Event Info
« on: November 20, 2014, 01:37:24 AM »
Set Event Data and Get Event Info are 2 actions I just came across.
https://hutonggames.fogbugz.com/default.asp?W531
https://hutonggames.fogbugz.com/default.asp?W530

I have been using another method:
1. set the required target FSM's variable(s),
2. then send an event to the target FSM to do something with those variable(s) set right before.

If I understand correctly?
1. Set Event Data
2. then Broadcast event
3. then  Get Event Info in the target(s) FSM(s) you can do the same a bit more elegantly.

Is this right?
Which approach is better?

I would also appreciate some more explanation and use cases for the other actions in the StateMachine category. Some of them are gray areas still, but they seem like very powerful "allies" when used skilfully.

Thanks in advance,
szomaza

szomaza

  • Sr. Member
  • ****
  • Posts: 253
Re: Set Event Data and Get Event Info
« Reply #1 on: November 29, 2014, 08:31:41 AM »
"Broadcast Event" action is missing:
https://hutonggames.fogbugz.com/default.asp?W493

Has that been removed?

Obsolete?
There is a broadcast capability in the "Send Event" action, but the "Exclude Self" checkbox is not explained there:
https://hutonggames.fogbugz.com/default.asp?W34

And Exclude Self does not seem to work in the Send Event action.
Even when it is ticked another FSM on the same object receives the message.

br,
szomaza

IDontKnow

  • Junior Playmaker
  • **
  • Posts: 56
Re: Set Event Data and Get Event Info
« Reply #2 on: November 29, 2014, 12:55:47 PM »
And Exclude Self does not seem to work in the Send Event action.
Even when it is ticked another FSM on the same object receives the message.

I'm pretty sure that's the intended behavior of 'exclude self'. It's certainly how I'm using it.

I'm not sure if anything ever came of this thread: http://hutonggames.com/playmakerforum/index.php?topic=7849.0 , but a cursory search of the forums didn't turn up anything.

You could always make a post about it on the Action Requests board.
--

szomaza

  • Sr. Member
  • ****
  • Posts: 253
Re: Set Event Data and Get Event Info
« Reply #3 on: December 03, 2014, 09:19:40 AM »
Thanks for the info. That makes sense.

I thought it would exclude the whole game object not just that one FSM. Unfortunately I would need it to exclude the whole object.

Br,
szomaza