840+ Texture resources in a empty project

Hi, I’m new to Unity. Just read the reference of Resources.FindObjectsOfTypeAll and tested an empty project with following code:

function OnGUI () {
GUILayout.Label("All " + Resources.FindObjectsOfTypeAll(typeof(UnityEngine.Object)).Length);
GUILayout.Label("Textures " + Resources.FindObjectsOfTypeAll(typeof(Texture)).Length);
GUILayout.Label("AudioClips " + Resources.FindObjectsOfTypeAll(typeof(AudioClip)).Length);
GUILayout.Label("Meshes " + Resources.FindObjectsOfTypeAll(typeof(Mesh)).Length);
GUILayout.Label("Materials " + Resources.FindObjectsOfTypeAll(typeof(Material)).Length);
GUILayout.Label("GameObjects " + Resources.FindObjectsOfTypeAll(typeof(GameObject)).Length);
GUILayout.Label("Components " + Resources.FindObjectsOfTypeAll(typeof(Component)).Length);

}

And I’m pretty surprised it showed 841 textures, 42 meshes (the number changed overtime), 17 materials and 7 game objects already loaded, even there was an MainCamera object visible from the Hierarchy view.

Who does know what these resources are and for?

Thanks in advance!

Jinni

1 Answer

1

This may be resource Unity uses for Editor. Try to set up new project and measure again. Or print their names.

Glad you figured it out.