Skip to content

Commit

Permalink
Fix disappearing buttons
Browse files Browse the repository at this point in the history
When you exited edit mode and saving was done, it would not save any buttons that were not visible because they were for a different cockpit state.
  • Loading branch information
dantman committed Sep 16, 2018
1 parent 559a322 commit 04779fa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Assets/Scripts/CockpitStateSave.cs
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public State ReadState()
state.staticLocations.srvJoystick = SerializeTransform(srvJoystick.transform);
state.staticLocations.sixDofController = SerializeTransform(sixDofController.transform);

state.controlButtons = ReadControlButtons(root.GetComponentsInChildren<ControlButton>()).ToArray();
state.controlButtons = ReadControlButtons(root.GetComponentsInChildren<ControlButton>(true)).ToArray();

return state;
}
Expand Down

0 comments on commit 04779fa

Please sign in to comment.