mirror of
https://github.com/sinai-dev/UnityExplorer.git
synced 2025-06-24 01:12:41 +08:00
2.0.2
* Added support for viewing Texture2D (and Sprite) from the Inspector, and exporting them to PNG * Fixed an issue with generic methods not showing their return value type * Fixed an issue where destroyed UnityEngine.Objects would cause issues in the inspector * Fixed an issue when caching a ValueCollection of a Dictionary (the generic argument for the Entry Type is the last arg, not the first as with other Enumerables)
This commit is contained in:
@ -25,12 +25,22 @@ namespace Explorer.CacheObject
|
||||
return;
|
||||
}
|
||||
|
||||
//ExplorerCore.Log("Initializing InteractiveValue of type " + valueType.FullName);
|
||||
|
||||
InteractiveValue interactive;
|
||||
|
||||
if (valueType == typeof(GameObject) || valueType == typeof(Transform))
|
||||
{
|
||||
interactive = new InteractiveGameObject();
|
||||
}
|
||||
else if (valueType == typeof(Texture2D))
|
||||
{
|
||||
interactive = new InteractiveTexture2D();
|
||||
}
|
||||
else if (valueType == typeof(Sprite))
|
||||
{
|
||||
interactive = new InteractiveSprite();
|
||||
}
|
||||
else if (valueType.IsPrimitive || valueType == typeof(string))
|
||||
{
|
||||
interactive = new InteractivePrimitive();
|
||||
|
Reference in New Issue
Block a user