playMaker

Author Topic: Corrupted State Causes Param Fields to Disappear When Selecting Vars  (Read 3309 times)

memetic arts

  • Full Member
  • ***
  • Posts: 141
The following occurred while using PM 1.5.7f2/Unity 3.5.7f6/Mac OS X 10.7.5.

I'm using the iTween MoveTo action, and wanted to apply a variable to the speed parameter.  As soon as I clicked on the variable button next to the input field, the entire field disappeared.  I did the same with the other params in the group (Time and Delay), with the same result.

Cannot undo, and Reset only brings back Time and Speed, while also trashing all of my other param settings, so not a good option (I've got a path with 16 nodes set up).

I closed Unity without saving the project or scene, and when I reopened the bad settings were still intact -- no Time/Speed/Delay fields.

I tried removing the action entirely and re-adding it, with the same results.  However, when adding the Action to a different or new state, the variable selector worked just fine.

So what I thought was at first an iTween Action problem, may actually be more State-related.  Also seems to be GUI related, because the following error message was also generated.  Thanks for any/all help . . .

ArgumentException: GUILayout: Mismatched LayoutGroup.ValidateCommand
UnityEngine.GUILayoutUtility.BeginLayoutGroup (UnityEngine.GUIStyle style, UnityEngine.GUILayoutOption[] options, System.Type LayoutType)
UnityEditor.EditorGUILayout.BeginHorizontal (UnityEngine.GUIContent content, UnityEngine.GUIStyle style, UnityEngine.GUILayoutOption[] options)
UnityEditor.EditorGUILayout.BeginHorizontal (UnityEngine.GUILayoutOption[] options)
HutongGames.PlayMakerEditor.VariableEditor.FsmBoolField (UnityEngine.GUIContent label, HutongGames.PlayMaker.Fsm fsm, HutongGames.PlayMaker.FsmBool fsmBool)
HutongGames.PlayMakerEditor.ActionEditor.EditFsmBool (UnityEngine.GUIContent label, System.Object fieldValue, System.Object[] attributes)
HutongGames.PlayMakerEditor.ActionEditor.GUIForFieldTypes (System.String labelText, System.Type type, System.Object fieldValue, System.Object[] attributes)
HutongGames.PlayMakerEditor.ActionEditor.OnGUI (HutongGames.PlayMaker.FsmStateAction action, Boolean debugVariables, Boolean isPreview)
HutongGames.PlayMakerEditor.StateInspector.DoActionGUI (HutongGames.PlayMaker.FsmStateAction action)
HutongGames.PlayMakerEditor.StateInspector.DoActionsListGUI (HutongGames.PlayMaker.FsmState state)
HutongGames.PlayMakerEditor.StateInspector.DoActionsPanel ()
HutongGames.PlayMakerEditor.StateInspector.OnGUI ()
HutongGames.PlayMakerEditor.InspectorPanel.OnGUI (Rect area)
HutongGames.PlayMakerEditor.FsmEditor.OnGUI ()
FsmEditorWindow.OnGUI () (at /Users/rrodkin/Projects/ugruve/u-gruve 2D/ug2d_dev/ug2d_2013-06-24 copy/Assets/PlayMaker/Editor/FsmEditorWindow.cs:93)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture)

EDIT:  Jean, after writing this I realized that there is a tool in PlayMaker, so submitted through the tool as well.  Thx
« Last Edit: June 25, 2013, 01:55:28 PM by memetic arts »

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Corrupted State Causes Param Fields to Disappear When Selecting Vars
« Reply #1 on: June 25, 2013, 02:35:35 PM »
Hi,

 Thanks :) I was about to mention it as I spotted your post. Way to go :) thanks, this definitly helps Alex tackling all this properly. Most appreciated.

Can you confirm you don't have any custom actions here on that state? or actions using FsmVar?
 
bye,

 Jean

memetic arts

  • Full Member
  • ***
  • Posts: 141
Re: Corrupted State Causes Param Fields to Disappear When Selecting Vars
« Reply #2 on: June 25, 2013, 03:27:30 PM »
Confirmed, no custom actions, just MoveTo.

Another detail - the state/action is on a prefab, if that means anything.  The upside to that is that I was able to copy the prefab from my last good version of the project and restore the fields. While the bad behavior persists, I can at least use the prefabs and not have to re-enter the data for the 16 nodes (I had 4 prefabs like this).

On the other hand, if there's not an immediate easy answer, I may have to redo it anyway, as I do need to control the tween's speed over time with user input - and it seems the only way to do that is to feed variable data into it.

One last thing -- I didn't include the huge error message in the other bug report, sorry - but I guess you know where it is if you need it.  ;-)

Cheers

memetic arts

  • Full Member
  • ***
  • Posts: 141
Re: Corrupted State Causes Param Fields to Disappear When Selecting Vars
« Reply #3 on: June 25, 2013, 10:19:39 PM »
Okay, part of me feels like an idiot, but the other part of me feels like "hey, things shouldn't just disappear like that!"  :)

I found out why the fields disappeared, and how to get them back:

I apparently had "Hide Unused" checked on that particular state.  Unchecking it brought the fields back, set to "None".  Something tells me this is still a bug - the field shouldn't go away when you try to select a variable . . . come to think of it, with "hide unused" checked, if the field tested true for "unused", then it shouldn't have been visible in the first place.  So yes, still a bug!

At least now we know what's actually going on though . . .