- Home /
BundleLoader and Unity Package Updating Questions
Hello my name is Christian ( grfxman in the unity forum ) I found the BundleLoader in the Asset Store to be a helpful start on a project I'm doing. I was wondering if there is a way to make it smarter. Specifically I have a terrain grid that is saved as bundles. We update them frequently. I would like to pre-load them before we allow the log-in button to appear. But I was wondering if there is a way to check the file dates to allow it to only update newer packages. Seeing as they always have a name based on their grid position.
Also, since C# isn't my strong point, I'm also looking for an example of displaying a progress bar for the progress of package updating using BundleLoader.
Thank You for your time.
Answer by Ray-Pendergraph · Apr 03, 2011 at 07:48 PM
If you are running in the standalone players you can use System.IO to determine the timestamps of the unity3d files on the file system. Store them in the Data (Windows) or Content (Mac) and check them before you load them with WWW. If you are pulling the bundles from the web I am not aware of a similar mechanism but you could come up with some sort of catalog (like a text file or something) that you could pull across that provides the same information. Then you could just load that at startup and do comparison and then pull what you need.