playMaker

Author Topic: How to send trigger information to randomly chosen object? [SOLVED]  (Read 1790 times)

Jerry

  • Playmaker Newbie
  • *
  • Posts: 5
Hello,
I tried to find the answer myself but with no effect.
I will get to the point.
I have a few Generators. Each generates a spheres.
What I’m trying to create is a Cube that will send signal to a randomly chosen
Generator which allows me to generate single Sphere and come back to Idle state. In Idle state Generator will wait for next signal from Cube to generate next Sphere.

Does anyone have idea how to do it?

I presented the problem more specifically in the attached picture.

Thank you.
« Last Edit: July 13, 2014, 01:41:06 PM by Alex Chouls »

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 4003
  • Official Playmaker Support
    • LinkedIn
Re: How to send trigger information to randomly chosen object?
« Reply #1 on: July 12, 2014, 03:04:56 PM »
Use Send Event with Event Target set to Game Object. Use the randomly chosen object as the Game Object.

Have the target FSM respond to the event you send by generating a new object...

Alternatively you could use Activate Game Object and have the generating FSM deactivate itself when it's done. So each time the Game Object is activated it will run the FSM.

Jerry

  • Playmaker Newbie
  • *
  • Posts: 5
Re: How to send trigger information to randomly chosen object?
« Reply #2 on: July 13, 2014, 07:57:34 AM »
Thank you!
This is what I was looking for :)