- Home /
Load Custom User Textures from Folder In Desktop Build
I've been trying to figure out how I can have a user add a folder named "build" to the "Resources" folder with a desktop build of the game and then once the game is run, the game will go into that folder and load all textures into a List. (in the game, this list is changed to show the loaded textures)
I got everything working in the editor version. I import the textures from the Build folder to an object array using Resources.LoadAll and then add them to a list of 2d textures.
However, in the build, Unity doesn't load anything, it seems. I am just returned an empty list. I assume that Unity doesn't allow Resource.LoadAll to work with anything than what's already included in the build.
Basically, I want players to very easily be able to add a folder of their own custom images to the game and have these previews. I don't want them to have to fumble around with file import wizard or something during runtime; that's just messy in my opinion. I read that you can import custom textures using Resources.Load as long as they have exact names, but that would require players to rename all of their images (and at 25+ that would be inconvenient).
Is there any way to do this?
Your answer
Follow this Question
Related Questions
How to properly load textures? 2 Answers
Have some strange problem with Resources.Load 1 Answer
Loading textures runtime and assign to multiple button 1 Answer
How to change the image (texture) of a GUITexture in C#. 3 Answers
Why sprites don't load? 0 Answers