playMaker

Author Topic: FSM Array Contains  (Read 1724 times)

westingtyler

  • Sr. Member
  • ****
  • Posts: 277
    • My Video Game Projects Web Site
FSM Array Contains
« on: September 02, 2018, 11:48:49 AM »
I'm in an FSM processing game objects and such, and I need to say "if an game object with this same name exists in the Stamp Array or the Map Piece array, then set its material to X material."

The problem is, the Stamp Array and Map Piece Arrays are in another FSM.

The closest I can figure out is to do a "lock and send" where I set that other fsm's "game object to test" to this, set it's Processing bool to true, send the fsm event of checking its array, and wait for it to be done, and retrieve the result from there.

It would be super easy if I could just do a "FSM Array Contains" action to check another fsm's array for containing a thing.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7616
    • jinxtergames
Re: FSM Array Contains
« Reply #1 on: September 03, 2018, 01:18:10 AM »
Hi.
There is a 'fsm array copy' that you could use.

But i would suggest you to use 'array maker'

It works with a reference and can be easily accessed from any fsm.