From 077505a217f57d58164d3c98760554a22e837241 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=BCleyman=20Yasir=20KULA?= Date: Thu, 20 Aug 2020 12:24:37 +0300 Subject: [PATCH] Fixed a rare issue that occurs when searching properties with ref returns for references in Play mode --- Plugins/AssetUsageDetector/Editor/Utilities.cs | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Plugins/AssetUsageDetector/Editor/Utilities.cs b/Plugins/AssetUsageDetector/Editor/Utilities.cs index 50110c3..9064309 100644 --- a/Plugins/AssetUsageDetector/Editor/Utilities.cs +++ b/Plugins/AssetUsageDetector/Editor/Utilities.cs @@ -415,8 +415,8 @@ namespace AssetUsageDetectorNamespace if( typeof( Type ).IsAssignableFrom( type ) || type.Namespace == reflectionNamespace ) return true; - // Searching pointer variables for reference throws ArgumentException - if( type.IsPointer ) + // Searching pointers or ref variables for reference throws ArgumentException + if( type.IsPointer || type.IsByRef ) return true; return false; diff --git a/package.json b/package.json index e722c7a..60cd453 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "com.yasirkula.assetusagedetector", "displayName": "Asset Usage Detector", - "version": "1.8.5", + "version": "1.8.6", "description": "This editor extension helps you figure out at which places an asset or GameObject is used, i.e. lists the objects that refer to the asset. It is possible to search for references in the Assets folder (Project view) and/or in the scene(s) of your project. You can also search for references while in Play mode!" }