playMaker

Author Topic: Can not set object variable in xml select single node for XML proxy  (Read 9335 times)

elusiven

  • Full Member
  • ***
  • Posts: 233
  • Debt we all must pay...
Hi all,

Title says it all... It just keeps "None" and that's it, I press on the variable that I want to use which has the XML proxy, and it just keeps going "None" anyway... Any ideas? Thanks

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Can not set object variable in xml select single node for XML proxy
« Reply #1 on: November 15, 2016, 01:15:27 AM »
Hi,

 What version of DataMaker do you have? I thought the latest version I put on the Ecosystem fixed this.


 Bye,

 Jean

elusiven

  • Full Member
  • ***
  • Posts: 233
  • Debt we all must pay...
Re: Can not set object variable in xml select single node for XML proxy
« Reply #2 on: November 15, 2016, 05:31:08 AM »
I just upgraded to the newest, and error still persists...

I do now get an error though in the log..

ArgumentException: Object type HutongGames.PlayMaker.FsmGameObject cannot be converted to target type: HutongGames.PlayMaker.FsmEvent
Parameter name: val
System.Reflection.MonoField.SetValue (System.Object obj, System.Object val, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoField.cs:148)
System.Reflection.FieldInfo.SetValue (System.Object obj, System.Object value) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/FieldInfo.cs:150)
HutongGames.PlayMakerEditor.ActionEditor.DoVariableSelection (System.Object userdata) (at c:/Users/Alex/Documents/Unity/Playmaker/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/ActionEditor.cs:2893)
UnityEditor.GenericMenu.CatchMenu (System.Object userData, System.String[] options, Int32 selected) (at /Users/builduser/buildslave/unity/build/artifacts/generated/common/editor/GenericMenuBindings.gen.cs:122)

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Can not set object variable in xml select single node for XML proxy
« Reply #3 on: November 16, 2016, 03:48:08 AM »
Hi,

 Ok, you'll need to go through your actions, one of them has lost it's setup.

did you updated from Unity 4 to Unity 5 without first updating PlayMaker to 1.8 by any chance?

Bye,

 Jean

elusiven

  • Full Member
  • ***
  • Posts: 233
  • Debt we all must pay...
Re: Can not set object variable in xml select single node for XML proxy
« Reply #4 on: November 16, 2016, 04:52:22 AM »
I was upgrading from unity 5.3 to 5.4, but that was after this anyway... I had unity 5 from the beginning of the project. Don't have any action or state errors, what shall i do exactly??

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Can not set object variable in xml select single node for XML proxy
« Reply #5 on: November 17, 2016, 02:10:17 AM »
Hi,

 You need to go through your Select Single Node Actions and verify their setup, you'll likely find that one of the variable type is wrong now.

Bye,

 Jean

elusiven

  • Full Member
  • ***
  • Posts: 233
  • Debt we all must pay...
Re: Can not set object variable in xml select single node for XML proxy
« Reply #6 on: November 30, 2016, 05:08:17 AM »
They're all fine, my single nodes actions are all working correctly when I manually point it at the proxy gameobject. But the variable goes to None and spits out the error when I try to set it to read from variable for example. It doesn't let me set a variable.

I've been stuck on this for days now, is there any way to fix this?

ArgumentException: Object type HutongGames.PlayMaker.FsmString cannot be converted to target type: HutongGames.PlayMaker.FsmEvent
Parameter name: val
System.Reflection.MonoField.SetValue (System.Object obj, System.Object val, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoField.cs:148)
System.Reflection.FieldInfo.SetValue (System.Object obj, System.Object value) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/FieldInfo.cs:150)
HutongGames.PlayMakerEditor.ActionEditor.DoVariableSelection (System.Object userdata) (at c:/Users/Alex/Documents/Unity/Playmaker/Projects/Playmaker.source.unity/Assets/PlayMaker/Editor/Classes/ActionEditor.cs:2893)
UnityEditor.GenericMenu.CatchMenu (System.Object userData, System.String[] options, Int32 selected) (at /Users/builduser/buildslave/unity/build/artifacts/generated/common/editor/GenericMenuBindings.gen.cs:122)



600

  • Beta Group
  • Hero Member
  • *
  • Posts: 713
    • Flashing Lights
Re: Can not set object variable in xml select single node for XML proxy
« Reply #7 on: November 30, 2016, 05:24:50 AM »
Looks like the same error I have when using variable, posted on XML actions post:
http://hutonggames.com/playmakerforum/index.php?topic=2583.60

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Can not set object variable in xml select single node for XML proxy
« Reply #8 on: December 01, 2016, 02:24:50 AM »
Hi,

yes, that one is a know issue, I can't find a work around unfortunately. Will ping Alex, maybe he can't provide the old api method back.

Bye,

 Jean

elusiven

  • Full Member
  • ***
  • Posts: 233
  • Debt we all must pay...
Re: Can not set object variable in xml select single node for XML proxy
« Reply #9 on: December 01, 2016, 04:44:10 AM »
Jean,

Is there a way I can modify the data maker proxy to take in string of XML content from anywhere, like the persistence datapath instead of a text asset?

If not then I will have to wait for a fix

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Can not set object variable in xml select single node for XML proxy
« Reply #10 on: December 02, 2016, 03:12:39 AM »
Hi,

 yes, using the xml proxy is definitly recommended here.

Bye,

 Jean

elusiven

  • Full Member
  • ***
  • Posts: 233
  • Debt we all must pay...
Re: Can not set object variable in xml select single node for XML proxy
« Reply #11 on: December 02, 2016, 11:11:39 AM »
In the XML proxy, there is only a way to get data from text asset which is not really ideal and won't work with what I want to do.. I download an xml file to persistence data path, and then save xml content to a string that later playmaker fsm can use... Unfortunately I cannot set a variable in the xml select single node due to this bug and it's causing a lot of problems. Also some of my prefabs use this action and also lose reference to the proxy because I can't set the variable.... Do you have any ETA on this fix? Thanks

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Can not set object variable in xml select single node for XML proxy
« Reply #12 on: December 05, 2016, 08:50:52 AM »
Hi,

 Can you make a screenshot of where exactly you can't set the variable? I know they are several places and from your description, I am pretty sure I did an update to fix this, but want to make sure of where you are exactly.

 Bye,

 Jean

elusiven

  • Full Member
  • ***
  • Posts: 233
  • Debt we all must pay...
Re: Can not set object variable in xml select single node for XML proxy
« Reply #13 on: December 05, 2016, 09:48:46 AM »
Even better.. A video :P


Unity: 5.4.2f2

Playmaker: 1.8.3.f4
« Last Edit: December 05, 2016, 09:50:49 AM by elusiven »

elusiven

  • Full Member
  • ***
  • Posts: 233
  • Debt we all must pay...
Re: Can not set object variable in xml select single node for XML proxy
« Reply #14 on: December 08, 2016, 05:48:34 AM »
Hiiii, any updates on this Jean? My deadlines are getting tight :P