Playmaker Forum

PlayMaker Feedback => Action Requests => Topic started by: JennaReanne on July 03, 2013, 11:42:50 AM

Title: Extend "Set Event Data" action [SOLVED]
Post by: JennaReanne on July 03, 2013, 11:42:50 AM
Hello - I would love to be able to set multiple variables of the same type for event data.  For example, I'd like to send an event that has two int variables with it.  Right now we can only set one variable of each type.

Thanks!
Title: Re: Extend "Set Event Data" action
Post by: jeanfabre on July 04, 2013, 06:38:25 AM
Hi,

 I have a set of custom actions for this. Haven't officially released it yet, but its part of a set of utils for PlayMaker,

Get the PlayMaker Utils on the Ecosystem (http://j.mp/PlayMakerEcosystem).

(http://i.imgur.com/WCtC20c.png)

 . You'll have two new actions:

"Set Event Properties"
"Get Event Properties"

both are flexible: you define as much properties as you want and of the types you want.

 If you have questions, let me know.

Bye,

 Jean
Title: Re: Extend "Set Event Data" action
Post by: Bjakuja on July 31, 2013, 01:20:35 PM
Wow thanks a lot JeanFabre, this is just what I was looking for, now I can add what I want to my inventory.
I just need to solve that lag we spoke about in Playmaker help section and it will great, try to find that fix if you can, I tried with no success.
Thanks a lot for everything!
Title: Re: Extend "Set Event Data" action
Post by: Bjakuja on July 31, 2013, 02:01:09 PM
It's what I am looking for but for some reason it doesn't work like set event data and get event info. Yeah I define how many variables I want before sendig event but that object not receiving any properties as it should like in get/ set data. What it the problem here, I define everything and do I need to set keys to be same in set event properties and get event properties and set event properties?
I get this weird error :
and set event properties
Expected top level layout group missing! Too many GUILayout.EndScrollView/EndVertical/EndHorizontal?
UnityEditor.DockArea:OnGUI()
Title: Re: Extend "Set Event Data" action
Post by: jeanfabre on July 31, 2013, 02:15:12 PM
HI,

 yep, you need to match keys, as you are the one that defines them.

Not sure what happens with the error. what version of unity and playmaker are you using?

bye,

Jean
Title: Re: Extend "Set Event Data" action
Post by: Bjakuja on July 31, 2013, 02:23:38 PM
Yeah I am matching key but it doesn't work, Unity latest version 4.2 and Playmaker latest version 1.63 but I don't know what causing the problem, probably version compatibility if those are old actions?
Title: Re: Extend "Set Event Data" action
Post by: jeanfabre on August 05, 2013, 03:20:34 AM
Hi,

 ok, yes, there is an issue, I am trying to debug, because it works on a project, but not properly when installed on others... Not sure why yet, but will find it hopefully today.

bye,

 Jean
Title: Re: Extend "Set Event Data" action
Post by: jeanfabre on August 06, 2013, 09:20:50 AM
Hi,

 ok, I edited the system. it should work a lot better now. Can you test now with this package attached?

bye,

 Jean
Title: Re: Extend "Set Event Data" action
Post by: Bjakuja on August 10, 2013, 12:57:25 PM
Hi! I will test this later because i am on the vacation and when i am back i will test it. Thanks for everything ;)
Title: Re: Extend "Set Event Data" action
Post by: Bjakuja on August 19, 2013, 11:43:12 AM
Tested that attached package and it's working like a charm,now i can make what i  want especially with the inventory system ;)
If i encounter any bug i will let you know ;) Thanks Jean.
Cheers
Title: Re: Extend "Set Event Data" action [SOLVED]
Post by: JennaReanne on November 26, 2013, 03:14:14 PM
This works beautifully, thank you Jean!
Title: Re: Extend "Set Event Data" action [SOLVED]
Post by: Graham on October 11, 2016, 12:45:45 PM
This seems extremely useful, however it causes momentary stutter during the get event properties action. The lag is more noticeable in the updated version.

Any idea what's going on here?
Title: Re: Extend "Set Event Data" action [SOLVED]
Post by: jeanfabre on October 13, 2016, 02:01:50 AM
Hi,

 I can't see anything wrong in the profiler with your scene. I made it so that it returns to the space key watcher state so that I can do this several times, and in the profiler, everything is normal.

 - Can you profile on your end?
 - What version of Unity and PlayMaker?

Bye,

 Jean
Title: Re: Extend "Set Event Data" action [SOLVED]
Post by: Graham on October 14, 2016, 08:06:55 AM
Thanks for checking it out Jean. I am running Unity 5.3.6 with Playmaker 1.8.3. When I run with the profiler I get a massive CPU spike originating from BehaviourUpdate=>LogStringToConsole.

Using this information, I tried removing the first two debug logs "Debug.Log(keys.Value);" and "Debug.Log("found");" from the script. The spike is no longer apparent.
Title: Re: Extend "Set Event Data" action [SOLVED]
Post by: jeanfabre on October 25, 2016, 03:24:48 AM
Hi,

 I checked the code and it's commented out, I think it's because I need to now remove the package attached to this thread and let people download the utils from the ecosystem.

 Bye,

 Jean