Learn / Documentation / Playmaker Event Dispatcher
Scripting

Description

The Playmaker Event Dispatcher sends game events and/or button clicks (button names of the buttons that were clicked) to any Playmaker FSM.

When attached to a GameObject, the component ill search for a Playmaker FSM and set it as its TargetFsm (that receives the game events and/or button names).

NOTE: This component is available only if you have the Playmaker asset installed and if you enabled Playmaker support for it (in the Control Panel - General tab)

--- How To Use ---

The dispatcher auto targets the first FSM on the GameObject it gets attached to. The FSM reference can be overridden in the Inspector.

For the dispatcher to work with the target Playmaker FSM you have to create FSM Events named exactly as the Game Events or Button Names that you want to listen for and react to. The FSM Events, Game Events and Button Names are case sensitive.

To dispatch Game Events, you have to create, in the target FSM, Events named exactly as the Game Event commands you wants to catch.

To dispatch Button Clicks, you have to create, in the target FSM, Events named exactly as the Button Names you wants to catch.

Component Details

Gesture Listener
  • Manual – Link to the manual page for this component

  • YouTube – Link to the quick video tutorial for this component

  • Debug Mode – Enables relevant debug messages to be printed to the console

  • Target FSM – The target FSM that will receive all the game events and/or button clicks (names)

  • Override – Allows for the target FSM reference to be changed in the inspector

  • Dispatch Game Events – If enabled, all the game events will get dispatched to the target FSM

  • Dispatch Button Clicks – If enabled, all the button clicks (names) will get dispatched to the target FSM