Skip to content

Commit

Permalink
Get field type in singular scene getter, not element type.
Browse files Browse the repository at this point in the history
  • Loading branch information
tonygiang committed Aug 10, 2021
1 parent 560c18a commit 5d832c9
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Attributes/AutoPropertyAttribute.cs
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,7 @@ public static class AutoPropertyHandler
?.GetComponentsInParent(property.Field.FieldType, true)
.FirstOrDefault(),
[AutoPropertyMode.Scene] = property => MyEditor
.GetAllComponentsInSceneOf(property.Context,
property.Field.FieldType.GetElementType())
.GetAllComponentsInSceneOf(property.Context, property.Field.FieldType)
.FirstOrDefault(),
[AutoPropertyMode.Asset] = property => Resources
.FindObjectsOfTypeAll(property.Field.FieldType)
Expand Down

0 comments on commit 5d832c9

Please sign in to comment.