playMaker

Author Topic: Calling global events from C#[SOLVED]  (Read 2730 times)

mathius777

  • Playmaker Newbie
  • *
  • Posts: 38
Calling global events from C#[SOLVED]
« on: February 17, 2014, 06:28:22 PM »
Is it possible to call a global event from C#? You can access global variables in this way, but I don't see a way to call a global event. Thanks.
« Last Edit: February 17, 2014, 11:46:57 PM by jeanfabre »

mathius777

  • Playmaker Newbie
  • *
  • Posts: 38
Re: Calling global events from C#
« Reply #1 on: February 17, 2014, 09:04:51 PM »
Figured it out:

Code: [Select]
PlayMakerFSM.BroadcastEvent(FsmEvent.FindEvent("YourGlobalEventName"));

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Calling global events from C#
« Reply #2 on: February 17, 2014, 11:46:44 PM »
Hi,

 uhm, nice I did not know about the FindEvent() call! Very cool, I'll keep that in mind.

bye,

 Jean