Skip to content

Commit cf0fea5

Browse files
committed
Fixed 3D model assets' direct children not being pinged correctly when selected via a search result
1 parent 956aea1 commit cf0fea5

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Plugins/AssetUsageDetector/Editor/Utilities.cs

+6
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,12 @@ public static void GetObjectsToSelectAndPing( this Object obj, out Object select
177177
selection = objTR.gameObject;
178178
#endif
179179
}
180+
else if( prefabAssetType == PrefabAssetType.Model )
181+
{
182+
objTR = ( (GameObject) obj ).transform;
183+
while( objTR.parent != null && objTR.parent.parent != null )
184+
objTR = objTR.parent;
185+
}
180186
#else
181187
Transform objTR = ( (GameObject) obj ).transform;
182188
while( objTR.parent != null && objTR.parent.parent != null )

0 commit comments

Comments
 (0)