Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MeshFilter components not drawn #3

Closed
WazWaz opened this issue Oct 23, 2017 · 2 comments
Closed

MeshFilter components not drawn #3

WazWaz opened this issue Oct 23, 2017 · 2 comments

Comments

@WazWaz
Copy link

WazWaz commented Oct 23, 2017

MeshFilter components are somehow broken by InspectorEditor. The mesh is not shown:

2017-10-23

@WazWaz
Copy link
Author

WazWaz commented Oct 23, 2017

Workaround is to insert the following at start of InspectorEditor.OnInspectorGUI():

if (this.target as MeshFilter) { DrawDefaultInspector(); return; }

@dbrizov
Copy link
Owner

dbrizov commented Oct 23, 2017

Thanks mate. I fixed it more globally. All unity scripts don't have NaughtyAttributes. In that case I use the default inspector.

if (fields.All(f => f.GetCustomAttributes(typeof(NaughtyAttribute), true).Length == 0))
{
    this.DrawDefaultInspector();
}

@dbrizov dbrizov closed this as completed Oct 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants