Search Unity

Question how to debug a gameobject's inspector that is slowing the editor?

Discussion in 'Editor & General Support' started by calpolican, Jan 23, 2021.

  1. calpolican

    calpolican

    Joined:
    Feb 2, 2015
    Posts:
    425
    So, I have a scriptable object that has the initial state of my game, it has the serializable info for the levels and the serializable info of the enemies. There are many nested list of serializable items, like a serializable inventory for each character and a set of stats.
    Since I switch to unity 2020.1 showing this object in the inspector has become super slow, to the point that it's really unworkable. The only way to edit some values on the list is by hiding some other fields with a [HideInInspector]. I'm loosing too much time hiding stuff and then unhiding it after, and it gets difficult to debug at runtime too.
    Is not a custom editor, it does have property drawers to hide fields base on a bool or enum though.
    I'm wondering... how can I debug what's going on with this scriptable object's inspector, to see what's making the editor so slow?
     
    Last edited: Jan 23, 2021
  2. PraetorBlue

    PraetorBlue

    Joined:
    Dec 13, 2012
    Posts:
    7,909