x


Loading a Random Resource in a Folder Without Using Resources.LoadAll

I'm working on a game designed for use on an iPad 1, and I'm running into memory problems when trying to find a random texture. Basically, I need to pick a Texture at random, but when I try to use Resources.LoadAll, it exhausts the device's memory and crashes. I need to find a way to look at the file structure of the Resources folder without actually loading anything.

In other words, I need to find a random file name within a given folder, not a random file. However, I don't see any function in the documentation for Resources that looks like it could help me, and the files in Resources are compressed when compiled for the iOS.

more ▼

asked Dec 16 '11 at 09:00 PM

Jon_M gravatar image

Jon_M
1 6 6 7

(comments are locked)
10|3000 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x2194
x1957
x590
x326
x217

asked: Dec 16 '11 at 09:00 PM

Seen: 959 times

Last Updated: Dec 16 '11 at 09:00 PM