Get the list of resources folders/assets at runtime ?

Hello !

I have a particular request : I’m currently making a “training hack pack” for a Unity game I speedrun. To do so, I decompile the game files, add my lines of code and recompile them. It works well and I’ve been able to add many training features, but I would love to be able to add a functionality to load any asset on demand.
To load an asset , it seems that Resources.Load() is the way to go. However, I have no clue about the internal structure of the “resources” folder, since all the assets are compiled in .assets files without any reference of the original structure, so I don’t know the path I need to give to the function. In the game code, Resources.Load() is never called to load an asset so I can’t mimic their path. So my question is : in this context, is there a way to get a list of assets I can load (with their full path) ?

What I’ve tried yet :

  • I’ve tried to decompile files like “mainData”, “resources.assets” or “sharedassetsX.assets”, using many softwares, I see a lot of elements I would love to load, but no pathes
  • I’ve seen a lot answers using “AssetDatabase” or “EditorUtility”, but I don’t seem to have access of those (I can’t use the UnityEditor namespace in this context, remember that I decompile/recompile an existing game, I’m not in the Unity Editor)
  • I’ve tried using a C# file browsing like in this post, but the result if just listing all the “.assets” files that are at the root of the game folder.

Thank you =) !

~MetalFox Dioxymore

There may be a way to extract the resources names from Unity’s internal assetformat, however this question is not a development question related to game development in Unity and therefore off-topic. You are aware of the fact that you’re most likely violating the copyright of the rights holder of the game you’re decompiling?

It’s kind of embarrassing to see script kiddies to reach out to professional game developers to get assistance on their hacking activities…