Button for Function does not show in editor.

Issue #776 wontfix
Thomas Wilkinson created an issue

I followed the Game Manager video series and recreated the Game Manager. The issue I am having now is I added a new Scriptable Object with a few simple components and a function that would toggle a Boolean variable between true and false. I added a button with the Odin attribute tag so I would have a button to call the function and toggle the boolean more easily. However the button Never shows up in the inspector, even though everything else works fine. I’m not getting any errors, and I don’t see any reason why a button shouldn’t show up.

I’ll attach images showing the lack of button despite the other windows working just fine. I’m using Unity 2019.4.16f1, with Odin 3.0.4.0. Windows 10 OS fully updated as of 4/29/2021.

I realized the class inherited from the OdinEditorWindow and not Scriptable Object. Changing it to Scriptable Object fixed the issue, though I’m not sure why it would not show a button in the editor window when other editor windows have no problem showing buttons.

Comments (2)

  1. Tor Esa Vestergaard

    This is not an error, but a consequence of how OdinMenuEditorWindow works - unlike OdinEditorWindow, it does not inspect itself, but instead inspect a list of targets selected via the menu tree on the left-hand side of the window.

  2. Log in to comment