Search Unity

Editor.CreateEditor stops working after 60~ish calls

Discussion in 'General Discussion' started by JamesLeeNZ, Feb 12, 2018.

  1. JamesLeeNZ

    JamesLeeNZ

    Joined:
    Nov 15, 2011
    Posts:
    5,616
    Anyone else experienced this?

    Been working on an asset, and the code stopped working properly in one of the updates to Unity. Not sure which version, but after 60ish calls to Editor.CreateEditor, it stops creating a valid editor (this is for a gameobject). DrawPreview is just a grey box.

    Not helpful when im trying to generate a few hundred static previews for GUI buttons.

    I had a search through the issue tracker but couldnt find anything about it.