You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Attempts to set parameters of animation graph of type declared in managed code leads to problems with the editor.
Note 1.: I'm not sure if the bug is triggered only for C# structs. I didn't check for C++.
Note 2.: There seems to be no bugs in built game. The bug is very annoying, but does not cause issues in built game.
Steps to reproduce:
Declare a structure in C# code.
Create animation graph with this struct as input.
Run the game and modify its value via code.
Select the model with changed parameter in the editor (during runtime).
The editor crashes, sometimes recovering, sometimes not into a weird zombie state.
Flax version:
1.8.1
[ 00:01:06.905 ]: [Error] Native interop exception!
[ 00:01:06.908 ]: [Warning] Exception has been thrown. Invalid ManagedHandle
Stack strace:
at FlaxEngine.Interop.ManagedHandle.ManagedHandlePool.GetObject(IntPtr handle) in ...\FlaxEngine\Source\Engine\Engine\NativeInterop.Managed.cs:line 536
at FlaxEngine.Interop.ManagedHandle.get_Target() in ...\FlaxEngine\Source\Engine\Engine\NativeInterop.Managed.cs:line 380
at FlaxEngine.Interop.ManagedHandleMarshaller.NativeToManaged.ConvertToManaged(IntPtr unmanaged) in ...\FlaxEngine\Source\Engine\Engine\NativeInterop.Marshallers.cs:line 34
at FlaxEngine.AnimatedModel.Internal_GetParameterValue1(IntPtr __obj, Guid& id) in ...\FlaxEngine\Microsoft.Interop.LibraryImportGenerator\Microsoft.Interop.LibraryImportGenerator\LibraryImports.g.cs:line 28473
at FlaxEngine.AnimatedModel.GetParameterValue(Guid id) in ...\FlaxEngine\Cache\Intermediate\FlaxEditor\Windows\x64\Debug\Level\Level.Bindings.Gen.cs:line 1844
at FlaxEditor.CustomEditors.Dedicated.AnimatedModelEditor.<>c.<Initialize>b__0_0(Object instance, GraphParameter parameter, Object tag) in ...\FlaxEngine\Source\Editor\CustomEditors\Dedicated\AnimatedModelEditor.cs:line 31
at FlaxEditor.Surface.SurfaceUtils.DisplayGraphParameters(LayoutElementsContainer layout, GraphParameterData[] data, GetGraphParameterDelegate getter, SetGraphParameterDelegate setter, ValueContainer values, GetGraphParameterDelegate defaultValueGetter, CustomPropertySpawnDelegate propertySpawn) in ...\FlaxEngine\Source\Editor\Surface\SurfaceUtils.cs:line 316
at FlaxEditor.CustomEditors.Dedicated.AnimatedModelEditor.Initialize(LayoutElementsContainer layout) in ...\FlaxEngine\Source\Editor\CustomEditors\Dedicated\AnimatedModelEditor.cs:line 30
at FlaxEditor.CustomEditors.CustomEditor.Initialize(CustomEditorPresenter presenter, LayoutElementsContainer layout, ValueContainer values) in ...\FlaxEngine\Source\Editor\CustomEditors\CustomEditor.cs:line 124
at FlaxEditor.CustomEditors.Editors.GenericEditor.Initialize(CustomEditorPresenter presenter, LayoutElementsContainer layout, ValueContainer values) in ...\FlaxEngine\Source\Editor\CustomEditors\Editors\GenericEditor.cs:line 702
at FlaxEditor.CustomEditors.CustomEditorPresenter.RootEditor.Initialize(LayoutElementsContainer layout) in ...\FlaxEngine\Source\Editor\CustomEditors\CustomEditorPresenter.cs:line 181
at FlaxEditor.CustomEditors.CustomEditor.Initialize(CustomEditorPresenter presenter, LayoutElementsContainer layout, ValueContainer values) in ...\FlaxEngine\Source\Editor\CustomEditors\CustomEditor.cs:line 124
at FlaxEditor.CustomEditors.CustomEditorPresenter.RootEditor.Setup(CustomEditorPresenter presenter) in ...\FlaxEngine\Source\Editor\CustomEditors\CustomEditorPresenter.cs:line 157
at FlaxEditor.CustomEditors.CustomEditorPresenter.BuildLayout() in ...\FlaxEngine\Source\Editor\CustomEditors\CustomEditorPresenter.cs:line 400
at FlaxEditor.CustomEditors.CustomEditorPresenter.OnSelectionChanged() in ...\FlaxEngine\Source\Editor\CustomEditors\CustomEditorPresenter.cs:line 476
at FlaxEditor.CustomEditors.CustomEditorPresenter.Select(IEnumerable`1 objects) in ...\FlaxEngine\Source\Editor\CustomEditors\CustomEditorPresenter.cs:line 371
at FlaxEditor.Windows.PropertiesWindow.OnSelectionChanged() in ...\FlaxEngine\Source\Editor\Windows\PropertiesWindow.cs:line 77
at FlaxEditor.Modules.SceneEditingModule.OnSelectionChanged() in ...\FlaxEngine\Source\Editor\Modules\SceneEditingModule.cs:line 684
at FlaxEditor.States.PlayingState.RestoreSelection() in ...\FlaxEngine\Source\Editor\States\PlayingState.cs:line 129
at FlaxEditor.States.PlayingState.OnEnter() in ...\FlaxEngine\Source\Editor\States\PlayingState.cs:line 161
at FlaxEngine.Utilities.StateMachine.SwitchState(State nextState) in ...\FlaxEngine\Source\Engine\Utilities\StateMachine.cs:line 128
at FlaxEditor.States.EditorStateMachine.SwitchState(State nextState) in ...\FlaxEngine\Source\Editor\States\EditorStateMachine.cs:line 110
at FlaxEngine.Utilities.StateMachine.GoToState(State state) in ...\FlaxEngine\Source\Engine\Utilities\StateMachine.cs:line 88
at FlaxEngine.Utilities.StateMachine.GoToState[TStateType]() in ...\FlaxEngine\Source\Engine\Utilities\StateMachine.cs:line 62
at FlaxEditor.Modules.SimulationModule.OnUpdate() in ...\FlaxEngine\Source\Editor\Modules\SimulationModule.cs:line 310
at FlaxEditor.Editor.Update() in ...\FlaxEngine\Source\Editor\Editor.cs:line 492
[ 00:01:06.908 ]: [Warning] Exception has been thrown.
Invalid ManagedHandle
The text was updated successfully, but these errors were encountered:
Issue description:
Attempts to set parameters of animation graph of type declared in managed code leads to problems with the editor.
Note 1.: I'm not sure if the bug is triggered only for C# structs. I didn't check for C++.
Note 2.: There seems to be no bugs in built game. The bug is very annoying, but does not cause issues in built game.
Steps to reproduce:
The editor crashes, sometimes recovering, sometimes not into a weird zombie state.
Flax version:
1.8.1
The text was updated successfully, but these errors were encountered: