handcircus / unity-resource-checker Goto Github PK
View Code? Open in Web Editor NEWEditor utility for unity to help check resources in the current scene (including active textures, their sizes, materials, meshes and which objects are using them)
Editor utility for unity to help check resources in the current scene (including active textures, their sizes, materials, meshes and which objects are using them)
Assets/Editor/ResourceChecker.cs(376,65): error CS0246: The type or namespace name Texture2DArray' could not be found. Are you missing a using directive or an assembly reference? Assets/Editor/ResourceChecker.cs(395,67): error CS0246: The type or namespace name
Texture2DArray' could not be found. Are you missing a using directive or an assembly reference?
Assets/Editor/ResourceChecker.cs(396,56): error CS0246: The type or namespace name Texture2DArray' could not be found. Are you missing a using directive or an assembly reference? Assets/Editor/ResourceChecker.cs(1027,40): error CS0246: The type or namespace name
Texture2DArray' could not be found. Are you missing a using directive or an assembly reference?
Assets/Editor/ResourceChecker.cs(1028,56): error CS0246: The type or namespace name `Texture2DArray' could not be found. Are you missing a using directive or an assembly reference?
Crunched textures do not calculate.
Has the following compile errors on Unity 2017.4.2f2. Resource Checker v2.1.
Assets/Editor/ResourceChecker.cs(286,23): error CS0117: UnityEngine.TextureFormat' does not contain a definition for
ATF_RGB_DXT1'
Assets/Editor/ResourceChecker.cs(287,23): error CS0117: UnityEngine.TextureFormat' does not contain a definition for
ATF_RGBA_JPG'
Assets/Editor/ResourceChecker.cs(288,23): error CS0117: UnityEngine.TextureFormat' does not contain a definition for
ATF_RGB_JPG'
Assets/Editor/ResourceChecker.cs(783,10): error CS0103: The name ac' does not exist in the current context Assets/Editor/ResourceChecker.cs(796,26): error CS0103: The name
cnt' does not exist in the current context
Assets/Editor/ResourceChecker.cs(805,29): error CS0103: The name m' does not exist in the current context Assets/Editor/ResourceChecker.cs(807,29): error CS0103: The name
m' does not exist in the current context
Every time I compile within visual studio, the console window prints out the following:
------ Build started: Project: Assembly-CSharp-Editor, Configuration: Debug Any CPU ------
C:\Code\MyProject\Assets\Editor\ResourceChecker.cs(970,10): info UNT0014: T is not a Unity Component
C:\Code\MyProject\Assets\Editor\ResourceChecker.cs(971,24): info UNT0014: T is not a Unity Component
========== Build: 2 succeeded or up-to-date, 0 failed, 0 skipped ==========
Is this normal?
in void CheckResources()
if (lightmapData.lightmapDir != null)
{
var textureDetail = GetTextureDetail(lightmapData.lightmapColor); // should be lightmapDir
if (!ActiveTextures.Contains(textureDetail))
ActiveTextures.Add(textureDetail);
}
Love this utility and I have been using it for a while. I noticed it stopped working for me when I upgraded to Unity 5 (it was reporting 0 resources in play mode even after a refresh). I checked the Asset Store to make sure I had the latest version which I did. Thankfully I checked the github repo because this version worked! Have we lost access to update this asset in the Asset Store?
Thanks for such a great resource!
When multiple scenes are in the Hierarchy the Checker will throw a "scene not loaded exception". This occurs regardless of whether or not they are listed in your Build Settings.
Line 647 misses a null check:
Original:
if (m != null)
{
AnimationClip clip = m as AnimationClip;
EditorCurveBinding[] ecbs = AnimationUtility.GetObjectReferenceCurveBindings(clip);
Fixed:
if (m != null)
{
AnimationClip clip = m as AnimationClip;
if (clip != null)
{
EditorCurveBinding[] ecbs = AnimationUtility.GetObjectReferenceCurveBindings(clip);
Thx for sharing this very useful Asset!
Give feedback if you saw my message!
Most likely, it's in the format that unity chooses by default. That is, if you change it to RGB32, then everything is displayed as it should, and this format does not seem to be supported.
Дайте обратную связь если увидели моё сообщение!
Скорее всего дело в формате, который юнити выбирает по умолчанию. То есть если поменять на RGB32 то всё отображается как надо, а данный формат похоже не поддерживается.
As stated, when material does not have "_MainTex" property, script will spam in console errors.
Solution is to change:
Line 360
from
if (tDetails.material.mainTexture!=null) GUILayout.Box(tDetails.material.mainTexture, GUILayout.Width(ThumbnailWidth), GUILayout.Height(ThumbnailHeight));
to
if (tDetails.material.HasProperty("_MainTex") && tDetails.material.mainTexture!=null) GUILayout.Box(tDetails.material.mainTexture, GUILayout.Width(ThumbnailWidth), GUILayout.Height(ThumbnailHeight));
Line 564
from
if (tMaterial.mainTexture != null && !dependencies.Contains(tMaterial.mainTexture))
to
if (tMaterial.HasProperty("_MainTex") && tMaterial.mainTexture != null && !dependencies.Contains(tMaterial.mainTexture))
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.