playMaker

Author Topic: ArrayList send Event To Game Objects Rejects Events  (Read 302 times)

Macol90

  • Playmaker Newbie
  • *
  • Posts: 15
    • View Profile
ArrayList send Event To Game Objects Rejects Events
« on: March 18, 2019, 08:33:01 AM »
"ArrayList send Event To Game Objects" rejects events unless they are assigned to the State the Action resides in. Doesn't matter if the event is global or used a dozen times in the FSM, "send Event" refuses to work.  ???

This is a problem because I need to be able to track down where Events are being used. Right now if I switch "RESET" to "UI RESET" in the Array's objects I have to track down the "Send Event by Name" Actions, and with a big project this can be a big pain in the butt!   >:(

In the last year and a half I've googled this issue at least a half dozen times, hoping someone would fix it, or maybe suggest solutions. The two or three threads I've found say it's fixed or seem to trail off... Please fix this!

I'm still learning so if there is an easy solution or I'm doing something wrong, I'm sorry, but as my mangled, bloated mess of a project gets bigger so does this problem.

Thank you for your help in advance!   ;D ;D ;D

Doh

  • Full Member
  • ***
  • Posts: 124
    • View Profile
Re: ArrayList send Event To Game Objects Rejects Events
« Reply #1 on: March 18, 2019, 08:46:34 AM »
Under the events tab, have you checked the box that turns the event into a global event?

Macol90

  • Playmaker Newbie
  • *
  • Posts: 15
    • View Profile
Re: ArrayList send Event To Game Objects Rejects Events
« Reply #2 on: March 18, 2019, 09:01:21 AM »
Yep, I've tried several events, basically all the ones in my FSM and a couple Global ones. I've also tried checking and unchecking the check boxes in the Action. The only Events that work are the ones assigned to the State it's in.

I'm pretty familiar with ArrayMaker. I duplicate a lot of objects with random Variables, all of which are in arrays. A couple other Actions have given me weird issues but I've been able to work them out or find a work around.

This Action though! So useful! Yet soooo frustrating!  :)

Doh

  • Full Member
  • ***
  • Posts: 124
    • View Profile
Re: ArrayList send Event To Game Objects Rejects Events
« Reply #3 on: March 18, 2019, 12:01:53 PM »
Have you made doubly sure that all of your variables are pointing to the right places? Correct recipient game object? Correct arraymaker reference? Maybe try removing the name from the actual array if it's the only arraylist on that object (this would remove potential manual input error from this scenario).

Could you perhaps have an FSM on the game object that holds the array containing the action in question? Then send an event to that FSM from the one shown in the picture? (my thinking being that it may not give you the error as the action would be onboard the object with the arraylist)

As another work around you could cycle through the array, getting each item one at a time and sending an event to each object manually. You could also do this with a normal Playmaker array, maybe a global array so that it's simpler to access.

If none of this would work in your situation then please provide images of everything involved, including each relevant tab (variables, events...).
« Last Edit: March 18, 2019, 12:04:53 PM by Doh »

Macol90

  • Playmaker Newbie
  • *
  • Posts: 15
    • View Profile
Re: ArrayList send Event To Game Objects Rejects Events
« Reply #4 on: March 18, 2019, 03:45:51 PM »
Let there be no doubt I haven't tried everything!   ;)

New Project, Current Versions of everything (except Unity because I couldn't find release notes for the -just released- version) with everything ligitemently setup with Global Events, Array and FSMs and everything.

Please try this for yourselves, I can't be the only one seeing this.

Athin

  • Junior Playmaker
  • **
  • Posts: 98
    • View Profile
Re: ArrayList send Event To Game Objects Rejects Events
« Reply #5 on: March 18, 2019, 05:35:01 PM »
Hey there,

If I'm understanding this correctly, what you can do is set the "Exclude self" option for the action and then just make a dummy event to get rid of that error.  The action will be happy now that it has that event in its state but never fires off since the event excludes itself. 

That was my work around at least. 

Macol90

  • Playmaker Newbie
  • *
  • Posts: 15
    • View Profile
Re: ArrayList send Event To Game Objects Rejects Events
« Reply #6 on: March 18, 2019, 06:07:01 PM »
Dude!  That's so simple! I thought about doing it before, but somehow I felt defeated. Like I knew it shouldn't work that way so I didn't do it, mostly I didn't like the clutter.   :-\

It's a pretty good work around though, but if someone could try to fix this problem (*cough* Jean *cough*) I would really appreciate it! If I had the skills I would've written an alternative Action months ago.    :)

Alternatively I can use "ArrayList Get Next" and send the event individually but I'm trying to minimize overhead as much as possible. I'm working with dozens and dozens of objects and the frame count dips when Get Next is is used mid gameplay.