Playmaker Forum

PlayMaker Feedback => Action Requests => Topic started by: westingtyler on September 02, 2018, 11:48:49 AM

Title: FSM Array Contains
Post by: westingtyler 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.
Title: Re: FSM Array Contains
Post by: djaydino 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 (https://hutonggames.fogbugz.com/?W715)'

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